Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //by BloodMaster
- //hvala Luki P. - Za pomoc oko hook-anja...
- //hvala ZicMortalu na prijavi buga
- #include <a_samp>
- new Text:nekitext[MAX_PLAYERS];
- new str56[24];
- new tajmer[MAX_PLAYERS];
- new bool:Postoji56[MAX_PLAYERS] = false;
- stock Novac56(playerid,koliko)
- {
- if(koliko == 0) return 1;
- if(Postoji56[playerid] == true) return 1;
- Postoji56[playerid]=true;
- nekitext[playerid] = TextDrawCreate(498.000000, 100.000000, ".");
- TextDrawBackgroundColor(nekitext[playerid], 255);
- TextDrawFont(nekitext[playerid], 3);
- TextDrawLetterSize(nekitext[playerid], 0.500000, 1.000000);
- TextDrawColor(nekitext[playerid], -1);
- TextDrawSetOutline(nekitext[playerid], 0);
- TextDrawSetProportional(nekitext[playerid], 1);
- TextDrawSetShadow(nekitext[playerid], 1);
- if(koliko < 0) format(str56,sizeof str56,"~r~-~g~$~r~%d",-koliko);
- if(koliko > 0) format(str56,sizeof str56,"~g~$~y~%d",koliko);
- if(koliko == 0) format(str56,sizeof str56,"~g~$~b~%d",koliko);
- TextDrawSetString(nekitext[playerid],str56);
- TextDrawShowForPlayer(playerid,nekitext[playerid]);
- tajmer[playerid] = SetTimerEx("removetd56",5000,false,"i",playerid);
- return 1;
- }
- forward removetd56(playerid);
- public removetd56(playerid)
- {
- Postoji56[playerid]=false;
- TextDrawDestroy(nekitext[playerid]);
- KillTimer(tajmer[playerid]);
- return 1;
- }
- //hook
- forward bloodmaster_GivePlayerMoney(playerid, pare);
- public bloodmaster_GivePlayerMoney(playerid, pare)
- {
- return GivePlayerMoney(playerid, pare);
- }
- forward _BM_GivePlayerMoney(playerid, pare);
- public _BM_GivePlayerMoney(playerid, pare)
- {
- Novac56(playerid,pare);
- return CallRemoteFunction("bloodmaster_GivePlayerMoney", "ii", playerid, pare);
- }
- #define GivePlayerMoney _BM_GivePlayerMoney
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement