Spawning Bikes

Started by 4K., Mar 21, 2016, 12:05 PM

Previous topic - Next topic

4K.

How can I spawn bikes without making them fall. When the explode and respawn they fall from a little height and maybe this makes them fall. I tried editing the z coordinates of the bikes but sometimes they are underground and sometimes have fallen.. So can someone help me to keep them standing when they fall?
Btw I'm referring to all bikes of VCMP.

Ty.

KAKAN

Edit the angle of that bike. That worked for me.
oh no

.

#2
Just spawn them a little lower than the player position.
_veh <- null;

function onPlayerCommand(player, cmd, text)
{
    if (_veh) _veh.Delete();
    // Dummy position in front of the player
    local pos = Vector(player.Pos.x - 5.0, player.Pos.y, player.Pos.z);
    // Decrease the spawn position height by 0.5 units
    pos.z -= 0.5;
    // Use that position to spawn
    _veh = CreateVehicle(191, player.World, pos, 0, 0, 0);
}

If you see them fall down straight when you spawn them then that's probably the case.
.