SA-MP Forums Archive
[Ajuda] Pq erro SetPlayerChatBubble? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Pq erro SetPlayerChatBubble? (/showthread.php?tid=557577)



Pq erro SetPlayerChatBubble? - oliverarrow - 14.01.2015

pawn Код:
new cabecastring[128];     
        format(cabecastring, sizeof cabecastring,"%s \n HP: %.1f | AR: %.1f",PlayerName(i), GetPlayerHealth(i) , GetPlayerArmour(i) ); // warning 202: number of arguments does not match definition
        SetPlayerChatBubble(i, cabecastring, COLOR_WHITE, 100.0, 10000);



Re: Pq erro SetPlayerChatBubble? - ZeZin - 14.01.2015

pawn Код:
%s \n HP: %.1f | AR: %.1f
Nгo seria %i


Re: Pq erro SetPlayerChatBubble? - oliverarrow - 14.01.2015

Nгo, esse .1f quer dizer tipo 1.0, nгo 1 e getplayerhealth e getplayerarmour tem que ser chamados como float
E alйm do mais o erro nгo estб aн, jб tentei trocar
Nem no \n, nem no | nгo sei o que й


Re: Pq erro SetPlayerChatBubble? - JonathanFeitosa - 14.01.2015

Que erro й ?


Re: Pq erro SetPlayerChatBubble? - oliverarrow - 14.01.2015

// warning 202: number of arguments does not match definition
Em:
format(cabecastring, sizeof cabecastring,"%s \n HP: %.1f | AR: %.1f",PlayerName(i), GetPlayerHealth(i) , GetPlayerArmour(i) );


Re: Pq erro SetPlayerChatBubble? - WendeLKILL - 14.01.2015

pawn Код:
new Float:Heatlh,Float:Armour;
GetPlayerHealth(i,Health);
GetPlayerArmor(i,Armour);
pawn Код:
new cabecastring[70];
format(cabecastring, sizeof cabecastring,"%s \n HP: %.1f | AR: %.1f",PlayerName(i), Health , Armour );
SetPlayerChatBubble(i, cabecastring, COLOR_WHITE, 100.0, 10000);
Vocк errou nos parвmetros do GetPlayerHealth e GetPlayerArmour.