Robbing a shop
#1

I made a script that you rob a shop then the player make an animation then a object is created in front of him

The problem is that i can't make the object be created in front of him , the object ID is : 1829
Reply
#2

Something like this perhaps:

new object;
new bool: etc...
if (robbing the store == 1)
{
object=create object (1829)
}
else if (robbing the store == 0)
{
deleteobject(object)
}

Not this exactly but like this.
Reply
#3

ok but their must be Position , like GetPlayerPos(x,y,z) then CreateObject(x+something ,y+something,z+something); , but i dunno why when i make them the object don't be created as it under the ground or something
Reply
#4

Are you sure it's in the same virtual world and interior? Also that's in not under the ground or above the ceiling?
What object is 1829? Sometimes you need to check maybe the object creates above you like z+5, so then instead of CreateObject at X,Y,Z, you will need to put X,Y,Z-5, I hope you understand what I mean..
Reply
#5

Thanks , But I made that it make an Animation but the problem is that the Object is created but the Animation isn't Done.
PHP код:
CreateObject(1829,x+1,y,z,0.0,0.0,96.0);
ApplyAnimation(playerid,"ROB_BANK","CAT_Safe_Rob",4.1,1,1,1,1,1);
ApplyAnimation(playerid,"ROB_BANK","CAT_Safe_Rob",4.1,1,1,1,1,1); 
Reply
#6

Why did you apply the ApplyAnimation twice? Maybe that's why it doesn't work(Just guessing).
It can't be the object's problem..
Reply
#7

Made it only one , but when i remove the Object , the Animation is done correctly
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)