Show result in textdraw (AAD70) -
MartinLupen - 02.09.2011
Hi guys, i wanna put the result of the 2 teams (Attack and Defence) in a Textdraw.
I see the result with TeamRoundsWon[T_HOME] and TeamRoundsWon[T_AWAY] when i do /scores.
now i wanna do same but with textraw.
i try with
Код:
risultato = TextDrawCreate(526, 141, "TeamRoundsWon[T_HOME] / TeamRoundsWon[T_AWAY]");
TextDrawFont(risultato , 1);
TextDrawLetterSize(risultato , 1, 7);
TextDrawSetOutline(risultato , 0);
TextDrawSetProportional(risultato , 1);
TextDrawSetShadow(risultato , 1);
but whe i enter ingame i see only TeamRoundsWon
how can i do?

Thanks and sorry for my bad english >_<
Re: Show result in textdraw (AAD70) -
[MWR]Blood - 02.09.2011
First of all, you have to create an array for both the teams.
Re: Show result in textdraw (AAD70) -
MartinLupen - 02.09.2011
i'm not a pro scripter or other, i'm only a newby, so i don't know more function or other, any1 can explain me as well? here or on xfire or in PM.
xfire: martinlupen
Re: Show result in textdraw (AAD70) -
TheLoolyWiz - 02.09.2011
Italiano? :P
Re: Show result in textdraw (AAD70) -
MartinLupen - 02.09.2011
Quote:
Originally Posted by TheLoolyWiz
Italiano? :P
|
si xD
Re: Show result in textdraw (AAD70) -
MadeMan - 02.09.2011
How is it done in /scores ?
Re: Show result in textdraw (AAD70) -
MartinLupen - 02.09.2011
I try with this:
Up:
OnGameModeInit:
Код:
risultato = TextDrawCreate(451 ,130 , "Score");
TextDrawFont(risultato , 1);
TextDrawLetterSize(risultato , 0.6, 4.2);
TextDrawColor(risultato , 0xfaf5f5FF);
TextDrawSetOutline(risultato , false);
TextDrawSetProportional(risultato , true);
TextDrawSetShadow(risultato , 1);
OnPlayerConnect:
Код:
new risultato1[128];
format(risultato1, sizeof(risultato1),"%d / %d",TeamRoundsWon[T_HOME],TeamRoundsWon[T_AWAY]);
TextDrawSetString(risultato, risultato1);
TextDrawShowForPlayer(playerid, risultato);
return 1;
when i try to Compile i see only 1 Warning:
C:\Users\pc\Desktop\AAD con Risultati\gamemodes\AAD70.pwn(1504) : warning 225: unreachable code
The 1504 line is:
Код:
if(playerid >= MAX_SERVER_PLAYERS)return Kick(playerid);
anyway, when i try to enter in my server, i see on the right 0 / 0 (the scores) but the server crash :\
any solutions?
Re: Show result in textdraw (AAD70) -
[MWR]Blood - 02.09.2011
What are you trying to check by doing that code!?
Re: Show result in textdraw (AAD70) -
MartinLupen - 02.09.2011
only show (with a textdraw) the result of 2 team (on A/D) but when i try to connect on my server, all crash
Re: Show result in textdraw (AAD70) -
[MWR]Blood - 02.09.2011
I meant this one.
pawn Код:
if(playerid >= MAX_SERVER_PLAYERS)return Kick(playerid);
I see no sense in this.
Remove it, and all should work fine.