SA-MP Forums Archive
Full Weapon Set - 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)
+--- Thread: Full Weapon Set (/showthread.php?tid=398842)



Full Weapon Set - raamiix - 11.12.2012

Can someone script a full weapon set? There it's give the player Full Health, Full Armor, And weapons?


Re: Full Weapon Set - ReVo_ - 11.12.2012

https://sampwiki.blast.hk/wiki/Weapons
https://sampwiki.blast.hk/wiki/GivePlayerWeapon
https://sampwiki.blast.hk/wiki/SetPlayerHealth
https://sampwiki.blast.hk/wiki/SetPlayerArmour


Re: Full Weapon Set - XtremeR - 11.12.2012

There are only some slots, you cant give all weapons at once.


Re: Full Weapon Set - raamiix - 11.12.2012

Quote:
Originally Posted by XtremeR
Посмотреть сообщение
There are only some slots, you cant give all weapons at once.
Can you fix that slots thing?


Re: Full Weapon Set - DaRk_RaiN - 11.12.2012

Not all weapons are included.
pawn Код:
if(!strcmp(cmdtext, "/allweaps", true, 8))
    {
    ResetPlayerWeapons(playerid);//Disarms the player
    SetPlayerHealth(playerid,1000);//Health 1000
    SetPlayerArmour(playerid,1000);//Armour 1000
    GivePlayerWeapon(playerid,9,1);//Saw
    GivePlayerWeapon(playerid,16,1000);//Grenade
    GivePlayerWeapon(playerid,24,10000);//Deagle
    GivePlayerWeapon(playerid,26,10000);//SawnOff
    GivePlayerWeapon(playerid,28,10000);//Uzi
    GivePlayerWeapon(playerid,31,10000);//M4
    GivePlayerWeapon(playerid,34,10000);//Sniper
    GivePlayerWeapon(playerid,38,100000);//Minigun xD
    GivePlayerWeapon(playerid,46,1);//Parachute
    return 1;
    }



Re: Full Weapon Set - raamiix - 11.12.2012

Quote:
Originally Posted by DaRk_RaiN
Посмотреть сообщение
Not all weapons are included.
pawn Код:
if(!strcmp(cmdtext, "/allweaps", true, 8))
    {
    ResetPlayerWeapons(playerid);//Disarms the player
    SetPlayerHealth(playerid,1000);//Health 1000
    SetPlayerArmour(playerid,1000);//Armour 1000
    GivePlayerWeapon(playerid,9,1);//Saw
    GivePlayerWeapon(playerid,16,1000);//Grenade
    GivePlayerWeapon(playerid,24,10000);//Deagle
    GivePlayerWeapon(playerid,26,10000);//SawnOff
    GivePlayerWeapon(playerid,28,10000);//Uzi
    GivePlayerWeapon(playerid,31,10000);//M4
    GivePlayerWeapon(playerid,34,10000);//Sniper
    GivePlayerWeapon(playerid,38,100000);//Minigun xD
    GivePlayerWeapon(playerid,46,1);//Parachute
    return 1;
    }
I'm using CMD:
Can you change it?


Re: Full Weapon Set - Squirrel - 11.12.2012

mhm simply just remove strcmp and add CMD
Код:
CMD:allweaps
{
    ResetPlayerWeapons(playerid);//Disarms the player
    SetPlayerHealth(playerid,1000);//Health 1000
    SetPlayerArmour(playerid,1000);//Armour 1000
    GivePlayerWeapon(playerid,9,1);//Saw
    GivePlayerWeapon(playerid,16,1000);//Grenade
    GivePlayerWeapon(playerid,24,10000);//Deagle
    GivePlayerWeapon(playerid,26,10000);//SawnOff
    GivePlayerWeapon(playerid,28,10000);//Uzi
    GivePlayerWeapon(playerid,31,10000);//M4
    GivePlayerWeapon(playerid,34,10000);//Sniper
    GivePlayerWeapon(playerid,38,100000);//Minigun xD
    GivePlayerWeapon(playerid,46,1);//Parachute
    return 1;
}



Re: Full Weapon Set - DaRk_RaiN - 11.12.2012

What with you guys?its
pawn Код:
CMD:allweaps(playerid, params[])
not
pawn Код:
CMD:allweaps
Anyways
pawn Код:
CMD:allweaps(playerid, params[])
{
    ResetPlayerWeapons(playerid);//Disarms the player
    SetPlayerHealth(playerid,1000);//Health 1000
    SetPlayerArmour(playerid,1000);//Armour 1000
    GivePlayerWeapon(playerid,9,1);//Saw
    GivePlayerWeapon(playerid,16,1000);//Grenade
    GivePlayerWeapon(playerid,24,10000);//Deagle
    GivePlayerWeapon(playerid,26,10000);//SawnOff
    GivePlayerWeapon(playerid,28,10000);//Uzi
    GivePlayerWeapon(playerid,31,10000);//M4
    GivePlayerWeapon(playerid,34,10000);//Sniper
    GivePlayerWeapon(playerid,38,100000);//Minigun xD
    GivePlayerWeapon(playerid,46,1);//Parachute
    SendClientMessage(playerid,0x80FFFFC8, "You recieve the weapons");//the message gets sent to the player
    SetPlayerChatBubble(playerid, "Run away from me!", 0x80FFFFC8, 100.0, 20000);//Creates a chat bubble above your head

    return 1;
}