Custom properties

hello, how can i move a cube(it’s a example) with a slider(custom property[‘prop’]) without drivers.?

it’s this but in the properties panel:

import bpy
class AddGem(bpy.types.Operator):

bl_idname = “mesh.primitivegemadd”
bl_label = “AddGem”
bl_description = “Create an offset faceted gem.”
bl_options = {‘REGISTER’, ‘UNDO’}
segments = bpy.props.FloatProperty(name=“Segments”,
description=“Longitudial segmentation”,
def execute(self, context):[‘Cube’].location.x = self.segments
return {‘FINISHED’}

thank you, and sorry for my english:o

you need to add an operator with button then you’ll be able to change it and it will affect the object cube location!

there must an example for this in that script that you can use

happy 2.5

thanks, but i want make it like a shape key no with button operator