30.12.2015, 16:13
(
Last edited by MafiaOink; 30/12/2015 at 07:23 PM.
)
Hey guys, today I'm presenting my Xmas Giftbox system, It uses dini for saving(I know it sucks but I did it in a real hurry) which saves the cooldown and you can edit it from toes finger to hair, You can set the cooldown, everything.. There is a /gift command scripted which will be used to get a random gift, created from filterscript, then it will call a function to your gamemode which will send the id, and the gift will be added/given by gamemode because filterscript wont give actual money etc
Downloads
Version 1.1
Version 1.0
Change Log
Version 1.1
[+] Added Y_INI
[-] Removed Dini
[!] Fixed a problem in Y_INI saving where GetPlayerPoolSize(); does not work in saving everyone(Replaced with MAX_PLAYERS)
Version 1.0
[*] Initial Release
Screenshots
http://imgur.com/a/DZanz
Downloads
Version 1.1
Version 1.0
Change Log
Version 1.1
[+] Added Y_INI
[-] Removed Dini
[!] Fixed a problem in Y_INI saving where GetPlayerPoolSize(); does not work in saving everyone(Replaced with MAX_PLAYERS)
Version 1.0
[*] Initial Release
Screenshots
http://imgur.com/a/DZanz
Example used on SS(gamemode: grandlarc, forwarding is required!)
Code:
forward OnPlayerRetrieveGift(playerid, randomid); public OnPlayerRetrieveGift(playerid, randomid) { if(randomid == 1) { SendClientMessage(playerid, -1, "You won free 300 HP!"); SetPlayerHealth(playerid, 300); } else if(randomid == 2) { SendClientMessage(playerid, -1, "You won free 300 armour!"); SetPlayerArmour(playerid, 300); } else if(randomid == 3) { SendClientMessage(playerid, -1, "You won free deagle with 70 ammo!"); GivePlayerWeapon(playerid, 24, 70); } else if(randomid == 4) { SendClientMessage(playerid, -1, "You won free $9000!"); GivePlayerMoney(playerid, 9000); } else if(randomid == 5) { SendClientMessage(playerid, -1, "You won the Advanced Weapon Kit!"); GivePlayerWeapon(playerid, 24, 200); GivePlayerWeapon(playerid, 27, 200); GivePlayerWeapon(playerid, 29, 200); GivePlayerWeapon(playerid, 31, 200); GivePlayerWeapon(playerid, 8, 1); GivePlayerWeapon(playerid, 34, 200); } return 1; }