Pickups problem
#1

pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
    if(pickupid==pickup)
    {
        SetPlayerInterior(playerid, 12);
        SetPlayerPos(playerid, 2324.419921,-1145.568359,1050.710083);
    }
    if(pickupid==pickup2) //this pickup is inside the interior, I'm making it like a exit
    {
        SetPlayerPos(playerid, 265.23, 2895.79, 9.26);
    }
    if(pickupid == WeapPickup)
    {
        if(team[playerid] != 2)
        {
            GivePlayerWeapon(playerid, wep1, ammo1-10); // -10 because the Pickup has got standard 10 ammo
            DestroyPickup(WeapPickup); // if one player pick up the weapon the Pickup will be destroyed for all players
        }
        else
        {
            ResetPlayerWeapons(playerid);
            SendClientMessage(playerid,YELLOW, "You do not know how to use that.");//zombies can't pick weapons up
        }
    }
    return 1;
}

when a player goes on pickup2 it sends him to those bugged places (all dark, no objects, worlds, etc...). What's wrong ?
Reply
#2

Since you are making it like an exit, make sure to set the player's interior (and virtual world if applicable) to the default (0). Setting him in a regular position with a different interior will cause that 'bug'.

This forum requires that you wait 120 seconds between posts. Please try again in 23 seconds.
Reply
#3

will try bro thx
Reply
#4

it worked bro, I though that for the exit i didn't need to put this :
pawn Код:
SetPlayerInterior(playerid, 0);
thxx
Reply
#5

Quote:
Originally Posted by marinov
Посмотреть сообщение
it worked bro, I though that for the exit i didn't need to put this :
pawn Код:
SetPlayerInterior(playerid, 0);
thxx
lol ofc u do
Reply
#6

I learned something today

Код:
This forum requires that you wait 120 seconds between posts. Please try again in 42 seconds.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)