2.5 what;s wrong with menu or register?

i got this piece of scdript and it;s notworkign anymore in 31315?
any idea what would be wrong and how to correct this ?


    #######################  Menu addition #####################
 
class infor_Roundedshapespanel1(bpy.types.Menu):
    bl_idname = "infor_Roundedshapespanel1"
    bl_label = "Rounded Shapes"                    #  Menu  script name
 
    def draw(self, context):
        layout = self.layout
        layout.operator_context = 'INVOKE_REGION_WIN'
 
 
        layout.operator("mesh.primitive_parabolaprimitive1_add",
            text="Primitive Parabole")
        layout.operator("mesh.primitive_halfcircle2_add",
            text="Angle circle")
 
######################################################
 
 
# Register the operators
 
def register():
    bpy.types.register(infor_Roundedshapespanel1)
 
 
# Then add new menu 
 
# Add "Add Primitives " menu to the "Add Mesh" menu on top header
 
 
import space_info
 
menu_func = (lambda self,
    context: self.layout.menu("infor_Roundedshapespanel1"))
 
if __name__ == "main":
 register()
 
 

any more need for unregister or may be something new in latest API?

Thanks for any help

Yeah, register is now implicit.

so i could remove this register unregister thing completely

ok is there any other thing that has change in last 2 or 3 weeks

cause cannot make this script work anymore!

and would like to re start it in latest built like 315

don’t know what about menu cahnges ?

in 315 i dont’ get any errors but don’t see the new menu added
so somethings else is missing here !

i can see bottom tool panel the run script thing
but no new menu item added in menu mesh !

any help appreciated

happy 2.5 and thanks

i tried this olod script in 31315 but refuse to wokr
by adding panel in operators’ panel

and no erros given on console

so can someone tell me what’s wrong with this register oe menu may be
in latest built



import bpy
import mathutils
from math import *
from bpy.props import *
import random
	

	
class initvar:
	
	def __init__(self, name):
		self.name = name
		 
	
	nmin=1.0
	nmax=10.0
	
	xrnd1=random.uniform(nmin,nmax)   
	yrnd1=random.uniform(nmin,nmax) 
	zrnd1=random.uniform(nmin,nmax) 
	
	

	seg1 = IntProperty(name="Segments X",
		description="Number  segments X",
		default=16, min=4, max=100)
	
	
	xloc = FloatProperty(name="X Loc",
		description="X location",
		default=xrnd1, min=1.0, max=100.0)
	
	
	yloc = FloatProperty(name="Y Loc",
		description="Y location",
		default=yrnd1, min=1.0, max=100.0)
	
	zloc = FloatProperty(name="Z Loc",
		description="Z location",
		default=zrnd1, min=1.0, max=100.0)
	

	
	
	

	
class addprimitiveparabola1(bpy.types.Operator):
	
	
	
	bl_idname = "mesh.primitive_parabolaprimitive1_add"
	
	
	bl_label = "Add Primitive Parabola"
	bl_options = {'REGISTER', 'UNDO'}
	
	span = FloatProperty(name="Base Arch Span",
		description="Arch Span",
		default=5.0, min=1.0, max=100.0)
	
	rise= FloatProperty(name=" Arch rise",
		description="Arch rise",
		default=10.0, min=1.0, max=100.0)
	
	aa= initvar										# Instantiate the init class
	
	seg1 =initvar.seg1
	xloc =initvar.xloc
	yloc =initvar.yloc
	zloc =initvar.zloc
	xrnd1=initvar.xrnd1
	yrnd1=initvar.yrnd1
	zrnd1=initvar.zrnd1
	
	
	def execute(self, context):
		xloc = self.properties.xloc
		yloc = self.properties.yloc
		zloc = self.properties.zloc
	
		span = self.properties.span
		rise = self.properties.rise
		seg1 = self.properties.seg1
	
	
	
	
	
	
		return {'FINISHED'}
	
	
	
	
def corner1(verts,edges,medges,start, stop, del1,edgeId,edl1,edl2,radcurv,x0,y0):
	
	# Edl1  is First point    edl2  is last point   EdgeId is  the last Vert index
	
	print ('corner')
	
	return edl3			# Return  Last  edgeId
	
	
	
class addhalfcircle2(bpy.types.Operator):
	
	
	bl_idname = "mesh.primitive_halfcircle2_add"
	bl_label = "Add Angle circle"
	bl_options = {'REGISTER', 'UNDO'}
	
	
	seg1 = IntProperty(name="Segments ",
		description="Number  segments ",
		default=16, min=4, max=100)
	
	
	span = FloatProperty(name="Base Circle",
		description="base  circle",
		default=5.0, min=1.0, max=100.0)
	
	
	ang11 = FloatProperty(name="Angle a",
		description="Left Angle of Triangle",
		default=36.0, min=0.01, max=360)
	
	
	def execute(self, context):
	
		span  = self.properties.span
		seg1  = self.properties.seg1
		ang11 = self.properties.ang11
	
		print ('circle')
	
	
	
		return {'FINISHED'}
	
	
	
	#######################  Menu addition #####################
	
class infor_Roundedshapespanel1(bpy.types.Menu):
	bl_idname = "infor_Roundedshapespanel1"
	bl_label = "Rounded Shapes"					#  Menu  script name
	
	def draw(self, context):
		layout = self.layout
		layout.operator_context = 'INVOKE_REGION_WIN'
		
	
		layout.operator("mesh.primitive_parabolaprimitive1_add",
			text="Primitive Parabole")
		layout.operator("mesh.primitive_halfcircle2_add",
			text="Angle circle")
	
######################################################
	
	
	
import space_info
	
menu_func = (lambda self,
	context: self.layout.menu("infor_Roundedshapespanel1"))
	
	
	
#if __name__ == "main":
#	register()
	
	


Thanks for any help