Why server send this command 2 times ?
#1

When player enter checkpoint the server use my script TWO times ?
PHP код:
#define Money 100
SendClientMessage(playerid0xFFFFFFF"You earned 100$, keep working :-)");
GivePlayerMoney(playeridMoney); 
I want to server send this only one time.
Reply
#2

Why dont you just do this?

Код:
SendClientMessage(playerid, 0xFFFFFFF, "You earned 100$, keep working :-)"); 
GivePlayerMoney(playerid, 100);
Instead of defining shitloads of stuff
Reply
#3

because i want to define
Reply
#4

Alright, can you send the whole OnPlayerEnterCheckpoint?
Reply
#5

Quote:
Originally Posted by Lynchos
Посмотреть сообщение
Why dont you just do this?

Код:
SendClientMessage(playerid, 0xFFFFFFF, "You earned 100$, keep working :-)"); 
GivePlayerMoney(playerid, 100);
Instead of defining shitloads of stuff
Maybe he will sometimes repeat the same code in his gamemode or filterscript, and if he wants to change money amount he needs to search across his maybe 10000 lines gamemode to find that amount.

With define just change #define money and it's changed in all places inside his gamemode.

BTW: OnPlayerEnterCheckpoint is needed.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)