Page 1 of 1

irrEdit....extend the SceneNode propertylist

Posted: Tue Aug 29, 2006 3:14 pm
by sudi
Is there a way to extend the scenenode properties in irrEdit? to like set life points?

Posted: Tue Aug 29, 2006 4:01 pm
by Ico
I think you'd have to change some Irrlicht sources to achieve this as long as there isn't any common "tag" or "userdata" attribute. At least I haven't heard of any yet.

You should store your game data in your own format/class. You could create a class containing everything you need including a pointer to an ISceneNode. And then manage everything inside a vector, list or map (stl).

Then in IrrEdit you don't place any monsters - you just place boxes (for example) and use one (or more) of their attributes to define their "monster id" (or something compareable - maybe the color values?) and after loading you just parse those information and then drop/delete those boxes again. Another solution would be to save monster data etc. in a custom file and load it yourself.

Posted: Tue Aug 29, 2006 4:36 pm
by sudi
Yeah but there is an option to add userdata in irredit but isn't working....
ohh and i can't get the type of mesh with

irrGetSceneNodeProperty([node], "Type")

it says the property "Type" does not exist.

Posted: Wed Aug 30, 2006 8:48 pm
by sudi
Sry to pump....but isn't there anyone who could help me?

Posted: Wed Aug 30, 2006 10:57 pm
by vitek
With what? Calling the above function? It might help if you showed us a definition, or at least told us where we could find it.

Posted: Sat Sep 02, 2006 6:16 am
by niko
Sudi wrote:irrGetSceneNodeProperty([node], "Type")

Not possible currently, sorry. But going to add something like this in the next release.

Posted: Sat Sep 02, 2006 9:11 am
by sudi
@vitek
it's one of the script functions in irredit