Money Problem
#1

Helo SA-MP.com , I have a small problem with my FilterScript.

So, i have in my Gamemode a Anti Money Hack , when a player try to get money with Hack, Automatic , the server reset money. To give player money , in my Gamemode i use this function

PlayerInfo[playerid][pCash] = PlayerInfo[playerid][pCash] + 1500;
SetPlayerMoney(playerid, PlayerInfo[playerid][pCash]);

Also, i put in my FilterScript function that are in my Gamemode , To ResetMoney etc. by Didn't Work, A Good Scripter said me to use CallRemoteFunction, and he mentioned : You can create a function type:

forward FSGivePlayerCash(playerid,cash);
public FSGivePlayerCash(playerid,cash) { SetPlayerMoney(playerid, PlayerInfo[playerid][pCash]); }

And Call Function

I tried what he said, but didn't work,

I put what it said in Filterscript, and in my Gamemode i put at function OnPlayerConnect

CallRemoteFunction("FSGivePlayerCash", "d");

Here is my FS : http://pastebin.com/YghNwRbe

What cand i do in This Case, a solution Please?

PS: Sorry for my Language
Reply
#2

The syntax might be this ->
pawn Код:
CallRemoteFunction("FSGivePlayerCash", "dd", playerid, amount);
Reply
#3

(3812) : error 017: undefined symbol "amount"

Line 3812: CallRemoteFunction("FSGivePlayerCash", "dd", playerid, amount);
Reply
#4

Can you help me, please ?
Reply
#5

What the? I wrote the "amount" because I thought you would change it to numbers! You have to replace it with 100 or whatever you want.
Reply
#6

I solved the problem differently, but thanks for the help [I Respect you]
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)