1
Modification Help / Re: Spawn bricks inside bricks
« on: August 03, 2017, 10:30:13 AM »
I figured it out through some testing. Scheduling (delaying) the event to occur a few moments after fixed it, just as placing it a few moments after would.
If anyone needs it, this is how it looks
schedule( t , objID or 0, functionName, arg0, ... , argN )
If anyone needs it, this is how it looks
schedule( t , objID or 0, functionName, arg0, ... , argN )
Code: [Select]
function brickLesserPlantData::onPlant(%data, %obj)
{
Parent::onPlant(%data, %obj);
%client = %obj.client;
%pos = %obj.getPosition();
%pos = getWord(%pos, 0) SPC getWord(%pos, 1) SPC getWord(%pos, 2) + 0.1;
schedule(500, %obj, createBrick, %client, brickLesserPlantFlowerData, %pos, 1, 0);
}