Quote:
Originally Posted by pds2k12
[i]Try these, because all you did is -20 z = Up & Down, you probably decreased the z too much, that's why the object won't show because it's underground
pawn Код:
wplant[playerid] = CreateDynamicObject( 776, x, y, z , 0, 0, 96, GetPlayerVirtualWorld(playerid), GetPlayerInterior(playerid));
|
That's not the issue I have a timer which lifts the objects here is the timer.
Код:
forward GrowWeed(playerid);
public GrowWeed(playerid)
{
ClearAnimations(playerid);
new Float:x, Float:y, Float:z;
GetObjectPos(wplant[playerid], x, y, z);
MoveDynamicObject(wplant[playerid], x, y, z+1, 0.5, 0, 0, 0);
SetTimerEx("GrowWeed2", 300000, 0, "d", playerid);//
}
forward GrowWeed2(playerid);
public GrowWeed2(playerid)
{
new Float:x, Float:y, Float:z;
GetObjectPos(wplant[playerid], x, y, z);
MoveDynamicObject(wplant[playerid], x, y, z+1, 0.5, 0, 0, 0);
SendClientMessage(playerid, COLOR_SYSTEM, "Your plant has grown");
Ready[playerid] = 1;
isplanting[playerid] = 0;
}
forward GrowWeed3(playerid);
public GrowWeed3(playerid)
{
new Float:x, Float:y, Float:z;
GetObjectPos(wplant[playerid], x, y, z);
MoveDynamicObject(wplant[playerid], x, y, z-1, 0.5, 0, 0, 0);
SendClientMessage(playerid, COLOR_SYSTEM, "Your plant is dieing");
SetTimerEx("GrowWeed4", 180000, 0, "d", playerid);//
}
forward GrowWeed4(playerid);
public GrowWeed4(playerid)
{
new Float:x, Float:y, Float:z;
GetObjectPos(wplant[playerid], x, y, z);
MoveDynamicObject(wplant[playerid], x, y, z-2, 0.5, 0, 0, 0);
SendClientMessage(playerid, COLOR_SYSTEM, "Your plant has died!");
}
Also tried changing how I first put the object down like this..
Код:
wplant[playerid] = CreateDynamicObject( 776, x, y, z-20 , 0, 0, 96, GetPlayerVirtualWorld(playerid), GetPlayerInterior(playerid));