Tag mismatch - explaination please....
#1

pawn Код:
SetPlayerSkin(playerid, gSelectionItemsTag[playerid][selecteditem]);
        new Float:dinheiro, Float:preco = 100;
        new Float:ndinheiro;
        dinheiro = GetPlayerMoney(playerid);
        ndinheiro = floatsub(dinheiro, preco);
        ResetPlayerMoney(playerid);
        GivePlayerMoney(playerid, ndinheiro); //WARN here <---
        return;
Quote:

XxxxXX.pwn(684) : warning 213: tag mismatch

Some help? and explain pls.
Oh, and if someone can tell to me how to subtract money withiout this "thing"
Reply
#2

You are passing a float when you should be passing an integer. You could cast it as well, or just use the subtract operator instead of floatsub().
Reply
#3

pawn Код:
GivePlayerMoney(playerid,GetPlayerMoney(playerid) - amount of money to subtract);
Reply
#4

floatround(ndinheiro)
Reply
#5

Use English variable names. Okay? Thanks!
Reply
#6

Quote:
Originally Posted by Vince
Посмотреть сообщение
Use English variable names. Okay? Thanks!
learn other language, ok thanks
Reply
#7

its not hard to translate script and paste it here
Reply
#8

GetPlayerMoney returns an integer. Saving an integer in a float variable won't work.

Quote:
Originally Posted by mastermax7777
Посмотреть сообщение
learn other language, ok thanks
If someone wants answers from English people, it would be very nice if English variables were used. If people want to post Portuguese (I'm guessing this is Portuguese) variables in the Portuguese subforum, they're free to do so. But as long as this is an English forum, we would very much like to see English variable and function names.
Reply
#9

I agree you should use English. The functions are English; it makes sense. That's like writing a book, making the title and the chapters one language then the main page a different language.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)