SA-MP Forums Archive
[INFO]ICON - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [INFO]ICON (/showthread.php?tid=276333)



[INFO]ICON - TheBluec0de - 13.08.2011

how do I bring up the icons after the death of the player as well?

http://oi54.tinypic.com/w0qjr7.jpg


Re: [INFO]ICON - PhoenixB - 13.08.2011

Do you mean how to keep that pickup there when player also dies?

Try using the Type of pickup until you find the suitable one your looking for.

You can see the Pickup types and how to create them at CreatingPickups


Re: [INFO]ICON - TouR - 13.08.2011

pawn Код:
//under OnPlayerDeath
new Float:dPos[3];
GetPlayerPos(playerid, dPos[0], dPos[1], dPos[2]);
CreatePickup(model, type, dPos[0], dPos[1], dPos[2], Virtualworld);



Re: [INFO]ICON - TheBluec0de - 13.08.2011

yes but after a certain number of seconds to remove dorebbero. otherwise continue to appear unnecessary icons :\


Re: [INFO]ICON - PhoenixB - 13.08.2011

you have to define the certain type for the pickup. read through the available types https://sampwiki.blast.hk/wiki/PickupTypes that will show you all types for a pickup and the role it plays.


Re: [INFO]ICON - TheBluec0de - 13.08.2011

I'm just the pickups of all weapons of players


Re: [INFO]ICON - TouR - 13.08.2011

pawn Код:
//at the top of the script
#define DEATH_TIMER 10000 // i seted it 10000 mileseconds (10 seconds) change it to the time you wish

new
    DeathPickup[500];

//under OnPlayerDeath
new Float:dPos[3];
GetPlayerPos(playerid, dPos[0], dPos[1], dPos[2]);
DeathPickup[playerid] = CreatePickup(model, type, dPos[0], dPos[1], dPos[2], Virtualworld);
SetTimerEx("RemoveDeathPickup",DEATH_TIMER,0,"i",playerid);

//somewhere in your script
forward RemoveDeathPickup(playerid);
public RemoveDeathPickup(playerid)
{
    DestroyPickup(DeathPickup[playerid]);
    return 1;
}
A quick code i made this should work

EDIT: I changed the "1" on timer to "0" so the timer is not repeated"


Re: [INFO]ICON - PhoenixB - 13.08.2011

23
Pickupable, but doesn't disappear on pickup.

That may help you? Its pickupable and it also does not dissapear when the player picks it up. From there onwards its you to choose what the pickup does


Re: [INFO]ICON - TheBluec0de - 13.08.2011

it tells me that no model defined ...


Re: [INFO]ICON - TouR - 13.08.2011

The model should be a number... Check this https://sampwiki.blast.hk/wiki/Pickup_help