Pawno crashing
#1

Hey guys.

So when I add this,

PreparePlayerTextDraws();

or

PreparePlayerTextDraws(playerid);

to my GameModeInIt or OnPlayerConnect, then PAWNO crashes.

Here's my PreparePlayerTextDraws code.

pawn Код:
stock PreparePlayerTextDraws(playerid)
    {
        FuelTD[playerid] = TextDrawCreate(520.000000, 378.000000, "~r~FUEL:~l~ l~w~lllllllll~r~l~l~l");
        TextDrawBackgroundColor(FuelTD[playerid], 255);
        TextDrawFont(FuelTD[playerid], 1);
        TextDrawLetterSize(FuelTD[playerid], 0.360000, 1.399999);
        TextDrawColor(FuelTD[playerid], -1);
        TextDrawSetOutline(FuelTD[playerid], 1);
        TextDrawSetProportional(FuelTD[playerid], 1);

        SpeedoTD[playerid] = TextDrawCreate(520.000000, 391.000000, "~g~SPEED:~w~ 100 MPH");
        TextDrawBackgroundColor(SpeedoTD[playerid], 255);
        TextDrawFont(SpeedoTD[playerid], 1);
        TextDrawLetterSize(SpeedoTD[playerid], 0.360000, 1.399999);
        TextDrawColor(SpeedoTD[playerid], -1);
        TextDrawSetOutline(SpeedoTD[playerid], 1);
        TextDrawSetProportional(SpeedoTD[playerid], 1);

        MilesTD[playerid] = TextDrawCreate(520.000000, 404.000000, "~r~MILES:~w~ 0");
        TextDrawBackgroundColor(MilesTD[playerid], 255);
        TextDrawFont(MilesTD[playerid], 1);
        TextDrawLetterSize(MilesTD[playerid], 0.360000, 1.399999);
        TextDrawColor(MilesTD[playerid], -1);
        TextDrawSetOutline(MilesTD[playerid], 1);
        TextDrawSetProportional(MilesTD[playerid], 1);
        return 1;
    }
What can be wrong?
Reply
#2

Quote:
Originally Posted by ******
Посмотреть сообщение
Try a different editor, I tend to use Notepad++.
How to compile in Notepad++?
Reply
#3

Problem is here:

Код:
~r~FUEL:~l~ l~w~lllllllll~r~l~l~l
Try like this:

Код:
~r~FUEL: ll~w~lllllllll~r~lll
Reply
#4

Quote:
Originally Posted by Snich
Посмотреть сообщение
Problem is here:

Код:
~r~FUEL:~l~ l~w~lllllllll~r~l~l~l
Try like this:

Код:
~r~FUEL: ll~w~lllllllll~r~lll
It works! Thank you so much, +rep.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)