SA-MP Forums Archive
Awesome Warn - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Awesome Warn (/showthread.php?tid=515196)



Awesome Warn - kloning1 - 25.05.2014

pawn Код:
C:\Users\Fauzy Rahmat\gamemodes\RP.pwn(16) : warning 201: redefinition of constant/macro (symbol "TEXT_DRAW_FONT_MODEL_PREVIEW")
C:\Users\Fauzy Rahmat\Desktop\gamemodes\RP.pwn(765) : warning 215: expression has no effect
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


2 Warnings.
this code
pawn Код:
#define PTW PlayerTextDrawSetPreviewModel //ON TOP SCRIPT

PlayerText:CreateModelPreviewTextDraw(playerid, modelindex, Float:Xpos, Float:Ypos, Float:width, Float:height)
{
    new PlayerText:txtPlayerSprite = CreatePlayerTextDraw(playerid, Xpos, Ypos, ""); // it has to be set with SetText later
    PlayerTextDrawColor(playerid, txtPlayerSprite, 0xFFFFFFFF);
    PlayerTextDrawBackgroundColor(playerid, txtPlayerSprite, 0x88888899);
    PlayerTextDrawTextSize(playerid, txtPlayerSprite, width, height);
    PTW(playerid, txtPlayerSprite, modelindex); // THIS IS LINE 765
    PlayerTextDrawSetSelectable(playerid, txtPlayerSprite, 1);
    PlayerTextDrawShow(playerid,txtPlayerSprite);
    return txtPlayerSprite;
}

#define TEXT_DRAW_FONT_MODEL_PREVIEW //line 16



Re: Awesome Warn - SAMProductions - 25.05.2014

Код:
warning 201: redefinition of constant/macro (symbol "TEXT_DRAW_FONT_MODEL_PREVIEW")
Means it's already defined, don't define it anymore. You've defined it twice.