Posts: 66
Threads: 21
Joined: Jun 2012
Reputation:
0
Hey. This is my problem:
1. I come to some place.
2. I type /hydra
3. It spawns hydra and put me into hydra.
4. I left that place and come back later.
5. There is another hydra spawned at place where i spawned first hydra.
If you need any code, i will give you.
Posts: 308
Threads: 23
Joined: Jun 2012
Yes OFC We Need Code
Posts: 46
Threads: 3
Joined: Dec 2010
Reputation:
0
and where did you defined the X, Y , Z coordinateS?
Posts: 66
Threads: 21
Joined: Jun 2012
Reputation:
0
I just figured out that when i die in the spawned car and come back to place where its been spawned, there it is spawned.
Posts: 46
Threads: 3
Joined: Dec 2010
Reputation:
0
try changing this:
if(IsPlayerInAnyVehicle(playerid))
{
DestroyVehicle(GetPlayerVehicleID(playerid));
PutPlayerInVehicle(playerid, CreateVehicle(520, X, Y, Z+2, VAngle, -1, -1, -1), 0);
}
to this
if(IsPlayerInAnyVehicle(playerid))
{
DestroyVehicle(GetPlayerVehicleID(playerid));
PutPlayerInVehicle(playerid, CreateVehicle(520, X, Y, Z+2, VAngle, -1, -1, -1), 0);
return 1;
} This way, it may not conflict with the else. I think this should be the problem. The script goes to the if, but it doesn't stop, and then it goes to the else also.
Posts: 46
Threads: 3
Joined: Dec 2010
Reputation:
0
yeah I think that's the trick, but it still sounds strange that he found 2 hydras at the same spot. I mean after he was saying, he came back with the hydra that he creadet, at the place where he created the hydra, and found another hydra in that place...
Posts: 66
Threads: 21
Joined: Jun 2012
Reputation:
0
Ranama's solution not working.
xtreamer's solution not working.