Problem with /buy command....[SOLVED]
#1

Hi, i have a problem with command /buy, i have larp gamemode and i have modified that command.

Code below;

http://pawn.pastebin.com/QcejvHgz
_______________________________
Errors;
Код:
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2209) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2238) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2274) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2275) : error 004: function "SafeGivePlayerWeapon" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2302) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2773) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2784) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2796) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2800) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2812) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2824) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2836) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2848) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2860) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2872) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2884) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2896) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2908) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2920) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2933) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2937) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2941) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2945) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2949) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2953) : error 004: function "PlayerToPoint" is not implemented
C:\DOCUME~1\User\Desktop\LA-RP\GAMEMO~1\larp.pwn(2957) : error 004: function "PlayerToPoint" is not implemented

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


26 Errors.
I have created six 24/7 businesses for /buy command.
And i don't know where is the problem maybe someone can find it in code.


SOLVED
Reply
#2

You forgot a closing bracket somewhere.
Reply
#3

Maybe, but i can't find where...
Reply
#4

I solved the problem, but now when i want to buy something it shows me, that i have no cash for that, i can't find problem for that now.
Can someone please help me?
Reply
#5

As i see on your previous errors, you have server side cash, that means that GetPlayerMoney(playerid) wont work. You need something like GetPlayerSafeMoney.

Replace every GetPlayerMoney with your custom function.
Reply
#6

But in othes places GetPlayerMoney works, i think the problem is not there, but i'll try that.
EDIT: I don't even have GetPlayerSafeMoney or other similar functions, i always used GetPlayerMoney, and it worked.
Reply
#7

Quote:
Originally Posted by BumbiS*
But in othes places GetPlayerMoney works, i think the problem is not there, but i'll try that.
EDIT: I don't even have GetPlayerSafeMoney function, i always used GetPlayerMoney, and ir worked.
You can share the SafeGivePlayerMoney function so we can make a "Get" function if you dont already have.

Also are you sure that you use GetPlayerMoney and it works in other commands? If yes, then what server side system you use that works with GetPlayerMoney.
Reply
#8

I use LARP gamemode, and now i fix it little bit, in all shops i can buy everything if i have money, but in First 24/7 it always shows that i dont have money

And here is the function;

pawn Код:
public SafeGivePlayerMoney(plyid, amounttogive)
{
    new curHour, curMinute, curSecond;
    gettime(curHour, curMinute, curSecond);
    ScriptMoneyUpdated[plyid] = curSecond;
    if (amounttogive < 0)
    {
        GivePlayerMoney(plyid, amounttogive);
        ScriptMoney[plyid] = (ScriptMoney[plyid] + amounttogive);
    }
    else
    {
        ScriptMoney[plyid] = (ScriptMoney[plyid] + amounttogive);
        GivePlayerMoney(plyid, amounttogive);
    }
    return 1;
}
Reply
#9

I solved the problem, thanks for helping me
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)