Textdraw help
#1

Hello! i wanna make a box banned

or whatever.. anyways i get errors and i have no idea why.

Код:
   Textdraw17[playerid] = CreatePlayerTextDraw(468.250000, 148.500000, "usebox");
   TextDrawLetterSize(Textdraw0, 0.000000, 15.627778);
   TextDrawTextSize(Textdraw0, 128.625000, 0.000000);
   TextDrawAlignment(Textdraw0, 1);
   TextDrawColor(Textdraw0, 0);
   TextDrawUseBox(Textdraw0, true);
   TextDrawBoxColor(Textdraw0, 102);
   TextDrawSetShadow(Textdraw0, 0);
   TextDrawSetOutline(Textdraw0, 0);
   TextDrawFont(Textdraw0, 0);

   Textdraw18[playerid] = CreatePlayerTextDraw(258.125000, 148.166702, "Banned");
   TextDrawLetterSize(Textdraw1, 0.582499, 2.019999);
   TextDrawAlignment(Textdraw1, 1);
   TextDrawColor(Textdraw1, -16776961);
   TextDrawSetShadow(Textdraw1, 0);
   TextDrawSetOutline(Textdraw1, 1);
   TextDrawBackgroundColor(Textdraw1, 51);
   TextDrawFont(Textdraw1, 1);
   TextDrawSetProportional(Textdraw1, 1);

   Textdraw19[playerid] = CreatePlayerTextDraw(155.000000, 184.333328, "You have been banned from LSCNR");
   TextDrawLetterSize(Textdraw2, 0.487500, 1.996665);
   TextDrawAlignment(Textdraw2, 1);
   TextDrawColor(Textdraw2, -16776961);
   TextDrawSetShadow(Textdraw2, 0);
   TextDrawSetOutline(Textdraw2, 1);
   TextDrawBackgroundColor(Textdraw2, 51);
   TextDrawFont(Textdraw2, 3);
   TextDrawSetProportional(Textdraw2, 1);

   Textdraw20[playerid] = CreatePlayerTextDraw(139.375000, 229.833312, "If you think this ban was wrong please make a ban appeal on");
   TextDrawLetterSize(Textdraw3, 0.275624, 1.407498);
   TextDrawAlignment(Textdraw3, 1);
   TextDrawColor(Textdraw3, -16776961);
   TextDrawSetShadow(Textdraw3, 0);
   TextDrawSetOutline(Textdraw3, 1);
   TextDrawBackgroundColor(Textdraw3, 51);
   TextDrawFont(Textdraw3, 3);
   TextDrawSetProportional(Textdraw3, 1);

   Textdraw21[playerid] = CreatePlayerTextDraw(playerid, 203.750000, 264.833312, "www.lscnrsamp.tk");
   PlayerTextDrawLetterSize(playerid, Textdraw0[playerid], 0.449999, 1.600000);
   PlayerTextDrawAlignment(playerid, Textdraw0[playerid], 1);
   PlayerTextDrawColor(playerid, Textdraw0[playerid], -5963521);
   PlayerTextDrawSetShadow(playerid, Textdraw0[playerid], 0);
   PlayerTextDrawSetOutline(playerid, Textdraw0[playerid], 1);
   PlayerTextDrawBackgroundColor(playerid, Textdraw0[playerid], 51);
   PlayerTextDrawFont(playerid, Textdraw0[playerid], 2);
   PlayerTextDrawSetProportional(playerid, Textdraw0[playerid], 1);
Код:
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(459) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(470) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(480) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(490) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(500) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(501) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(501) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(501) : error 029: invalid expression, assumed zero
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(501) : fatal error 107: too many error messages on one line

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


9 Errors.
Reply
#2

Add
new playerid;
Reply
#3

PHP код:
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(459) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(460) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(461) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(462) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(463) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(464) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(465) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(466) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(467) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(468) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(470) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(471) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(472) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(473) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(474) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(475) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(477) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(478) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(480) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(481) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(482) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(483) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(484) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(485) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(486) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(487) : error 035: argument type mismatch (argument 1)

Compilation aborted.Pawn compiler 3.2.3664              Copyright (c) 1997-2006, ITB CompuPhase


26 Errors
. 
Reply
#4

Give the whole code
Reply
#5

Okay
PHP код:
   Textdraw17[playerid] = CreatePlayerTextDraw(468.250000, 148.500000, "usebox");
   
TextDrawLetterSize(Textdraw17, 0.000000, 15.627778);
   
TextDrawTextSize(Textdraw17, 128.625000, 0.000000);
   
TextDrawAlignment(Textdraw17, 1);
   
TextDrawColor(Textdraw17, 0);
   
TextDrawUseBox(Textdraw17, true);
   
TextDrawBoxColor(Textdraw17, 102);
   
TextDrawSetShadow(Textdraw17, 0);
   
TextDrawSetOutline(Textdraw17, 0);
   
TextDrawFont(Textdraw17, 0);

   
Textdraw18[playerid] = CreatePlayerTextDraw(258.125000, 148.166702, "Banned");
   
TextDrawLetterSize(Textdraw18, 0.582499, 2.019999);
   
TextDrawAlignment(Textdraw18, 1);
   
TextDrawColor(Textdraw18, -16776961);
   
TextDrawSetShadow(Textdraw18, 0);
   
TextDrawSetOutline(Textdraw18, 1);
   
TextDrawBackgroundColor(Textdraw1, 51);
   
TextDrawFont(Textdraw18, 1);
   
TextDrawSetProportional(Textdraw18, 1);

   
Textdraw19[playerid] = CreatePlayerTextDraw(155.000000, 184.333328, "You have been banned from LSCNR");
   
TextDrawLetterSize(Textdraw19, 0.487500, 1.996665);
   
TextDrawAlignment(Textdraw19, 1);
   
TextDrawColor(Textdraw19, -16776961);
   
TextDrawSetShadow(Textdraw19, 0);
   
TextDrawSetOutline(Textdraw19, 1);
   
TextDrawBackgroundColor(Textdraw19, 51);
   
TextDrawFont(Textdraw19, 3);
   
TextDrawSetProportional(Textdraw19, 1);

   
Textdraw20[playerid] = CreatePlayerTextDraw(139.375000, 229.833312, "If you think this ban was wrong please make a ban appeal on");
   
TextDrawLetterSize(Textdraw20, 0.275624, 1.407498);
   
TextDrawAlignment(Textdraw20, 1);
   
TextDrawColor(Textdraw20, -16776961);
   
TextDrawSetShadow(Textdraw20, 0);
   
TextDrawSetOutline(Textdraw20, 1);
   
TextDrawBackgroundColor(Textdraw20, 51);
   
TextDrawFont(Textdraw20, 3);
   
TextDrawSetProportional(Textdraw20, 1);

   
Textdraw21[playerid] = CreatePlayerTextDraw(playerid, 203.750000, 264.833312, "www.lscnrsamp.tk");
   
PlayerTextDrawLetterSize(playerid, Textdraw21[playerid], 0.449999, 1.600000);
   
PlayerTextDrawAlignment(playerid, Textdraw21[playerid], 1);
   
PlayerTextDrawColor(playerid, Textdraw21[playerid], -5963521);
   
PlayerTextDrawSetShadow(playerid, Textdraw21[playerid], 0);
   
PlayerTextDrawSetOutline(playerid, Textdraw21[playerid], 1);
   
PlayerTextDrawBackgroundColor(playerid, Textdraw21[playerid], 51);
   
PlayerTextDrawFont(playerid, Textdraw21[playerid], 2);
   
PlayerTextDrawSetProportional(playerid, Textdraw21[playerid], 1); 
PHP код:
new PlayerText:Textdraw17[MAX_PLAYERS];
new 
PlayerText:Textdraw18[MAX_PLAYERS];
new 
PlayerText:Textdraw19[MAX_PLAYERS];
new 
PlayerText:Textdraw20[MAX_PLAYERS];
new 
PlayerText:Textdraw21[MAX_PLAYERS]; 
Reply
#6

Never mind
You need to add after textdraw example
TextDrawFont(draw17[playerid], 3);
Reply
#7

I don't really think so cause i got more text draws they are working great execpt that one.
Reply
#8

Chage to this
Код:
new Text:Textdraw17[MAX_PLAYERS];
new Text:Textdraw18[MAX_PLAYERS];
new Text:Textdraw19[MAX_PLAYERS];
new Text:Textdraw20[MAX_PLAYERS];
new PlayerText:Textdraw21[MAX_PLAYERS];
+ The stock/public function which you are using to do this part doesnt have playerid. Try calling with that
Eg:
if You put this inside a function BanPlayer(pid) -> You have to change playerid to pid..
Just change pid to playerid and errors should go off
Reply
#9

If u write
new Draw17[MAX_PLAYERS];

You need to add after the textdraw[playerid]
Like Draw17[playerid]
Reply
#10

Quote:
Originally Posted by Mic_H
Посмотреть сообщение
Chage to this
Код:
new Text:Textdraw17[MAX_PLAYERS];
new Text:Textdraw18[MAX_PLAYERS];
new Text:Textdraw19[MAX_PLAYERS];
new Text:Textdraw20[MAX_PLAYERS];
new PlayerText:Textdraw21[MAX_PLAYERS];
+ The stock/public function which you are using to do this part doesnt have playerid. Try calling with that
Eg:
if You put this inside a function BanPlayer(pid) -> You have to change playerid to pid..
Just change pid to playerid and errors should go off
PHP код:
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(459) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(459) : warning 213: tag mismatch
C
:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(460) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(461) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(462) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(463) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(464) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(465) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(466) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(467) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(468) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(470) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(470) : warning 213: tag mismatch
C
:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(471) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(472) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(473) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(474) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(475) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(477) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(478) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(480) : error 017: undefined symbol "playerid"
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(480) : warning 213: tag mismatch
C
:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(481) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(482) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(483) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(484) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(485) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(486) : error 035: argument type mismatch (argument 1)
C:\Users\yan\Desktop\LSCNR\gamemodes\LSCNR.pwn(487) : error 035: argument type mismatch (argument 1)
Compilation aborted.Pawn compiler 3.2.3664              Copyright (c) 1997-2006, ITB CompuPhase
26 Errors
. 
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)