Quote: "Can you check if the command "sp set group renderer" is working correctly - I've tried every variation I can think of to try to get it working, but no joy.
I am creating a system, with 2 x renderers (1 x blend_add , 1 x blend_subtract), both with differet names set using "sp set name".
When I try to compile, the DBPro editor gives an error msg "Could not understand command at line xx" - which is the "sp set group renderer" command.
I am assuming this command should enable me to toggle between the renderers?
GeeBee"
Hi ! it's a typo ! actually the command should be "SP SET GROUP RENDERER" but there's a mistake in the string table and the command is "SP SET RENDERER" , so this is a small bug and will be fixed in the next release . till then u can use SP SET RENDERER (it won't be highlighted but it will work
).
Also beware using this command ! The command assigns an EXISTING renderer to a group which is already used in another group ! So:
system = SP CREATE SYSTEM (proto , posx,posy,posz)
myFirstGroup = SP ADD GROUP (system ,capacity , posx,posy,posz)
mySecondGroup = SP ADD GROUP (system ,capacity , posx,posy,posz)
myThirdGroup = SP ADD GROUP (system ,capacity , posx,posy,posz)
myFourthGroup = SP ADD GROUP (system ,capacity , posx,posy,posz)
//etc
// we create a renderer for the "myFirstGroup" and use this renderer for the other four groups too
theRenderer = SP SET QUAD RENDERER (myFirstGroup , texture , scaleX , scaleY , atlasZ , atlasY , beldnMode)
// so from now on you can use this "theRenderer" and add it to other groups :
SP SET RENDERER mySecondGroup , theRenderer
SP SET RENDERER myThirdGroup , theRenderer
SP SET RENDERER myFourthGroup , theRenderer
// so basically you will share 1 renderer between 4 groups. this // is useful if you want to save memory , (the renderer is allocated once) but nothing else...
// PS: And keep in mind that a Group can have Only 1 renderer !