Pickups
#1

If i make a pickup it will send me to the correct interior, if i make 2 pickups then the first one i created basicly disables itself so when i go over to it it does nothing and the new pickup works as it should.

What have i done wrong?

pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
    for(new i = 0; i < sizeof(BizInfo);i++)
    {
        if(pickupid == BizInfo[i][pickup])
        {
            SetPlayerInterior(playerid, BizInfo[i][intera]);
        }
    }
    return 1;
}
Reply
#2

are the pickup overlaying each other ?
Reply
#3

What do you mean by that? Touching each other? if you mean that, no they are not.
Reply
#4

show how you create the pickups
Reply
#5

pawn Код:
CMD:createbiz(playerid, params[])
{
    new Float:pos[3], inter;
    if(sscanf(params,"i",inter)) return SendClientMessage(playerid, -1, "USAGE: /createbiz");
    GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
    for(new i = 0; i < sizeof(BizInfo);i++)
    {
        BizInfo[i][enterx] = pos[0];
        BizInfo[i][entery] = pos[1];
        BizInfo[i][enterz] = pos[2];
        BizInfo[i][intera] = inter;
        BizInfo[i][pickup] = CreatePickup(1274, 1, BizInfo[i][enterx], BizInfo[i][entery], BizInfo[i][enterz], 0);
    }
    return 1;
}
Reply
#6

you are creating multiple pickup in the same pos!
You loop the same poss with how ever the BizInfo is big.
that will creat many Pickup's in the same positions which when pickedup will get confused.
Reply
#7

What do you mean in the same position ? Ingame i put them far appart..
I don't understand lol
Reply
#8

He is trying to tell you that the pickups are really overlaying eachother. You think you are creating 1,but it creates more than one,but because they are on the same position you see them as a single pickup.
Reply
#9

Oh, How can i solve this problem
Reply
#10

I don't know. Try to make your cmd like PPC housing createhouse cmd. Let me find it.

http://forum.sa-mp.com/showthread.ph...ht=ppc+housing

or the business script:

http://forum.sa-mp.com/showthread.ph...ht=ppc+housing
Reply


Forum Jump:


Users browsing this thread: 4 Guest(s)