Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(1 edit)

No you can't do it with the current system. The reason is when you change the geo value, the engine will have to re-calculate the 3d model data, that's a massive work because scripting is executed every frame.

figured it was worth asking about and the reasoning makes sense. though in the scripting manual it also says that things like Rot, Offset and Pivot are also listed as get only:

PVector3 Scale { get; }
PVector3 Rot { get; }
PVector3 Offset { get; }
PVector3 Pivot { get; } // the pivot of scale and rotation operation

even though you can have a script modify those temporarily. are those only modifiable because those aren't recalculating all the data per frame, just that one attribute?

No it's not like that. It's "get" only because the purpose is to get the pointer to the real Vector3 data (hence PVector3), after that you could modify it by access each individual field. Something like:

shape3D.Scale.x = 90

shape3D.Scale.y = 45

You got what i mean.