Error 010
#1

Hey there SA-MP,

I know I am not good in scripting so please, don't leave unnecessary comments here that I am silly. Perhaps, I am getting this error while compiling.

Here's the error:
Код:
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(312) : error 010: invalid function or declaration
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(323) : error 010: invalid function or declaration
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(334) : error 010: invalid function or declaration
Here's the code:
Код:
//Global Textdraws:

new Text:Textdraw7;
new Text:Textdraw8;
new Text:Textdraw9;


Textdraw7 = TextDrawCreate(641.375000, 430.833312, "usebox");
TextDrawLetterSize(Textdraw7, 0.000000, 1.692597);
TextDrawTextSize(Textdraw7, -2.000000, 0.000000);
TextDrawAlignment(Textdraw7, 1);
TextDrawColor(Textdraw7, 0);
TextDrawUseBox(Textdraw7, true);
TextDrawBoxColor(Textdraw7, 102);
TextDrawSetShadow(Textdraw7, 0);
TextDrawSetOutline(Textdraw7, 0);
TextDrawFont(Textdraw7, 0);

Textdraw8 = TextDrawCreate(5.000000, 429.916717, "Welcome to Ocean Stunting");
TextDrawLetterSize(Textdraw8, 0.341246, 1.623332);
TextDrawTextSize(Textdraw8, 58.125000, -42.583385);
TextDrawAlignment(Textdraw8, 1);
TextDrawColor(Textdraw8, -1378294017);
TextDrawSetShadow(Textdraw8, 0);
TextDrawSetOutline(Textdraw8, 0);
TextDrawBackgroundColor(Textdraw8, -1378294017);
TextDrawFont(Textdraw8, 3);
TextDrawSetProportional(Textdraw8, 1);

Textdraw9 = TextDrawCreate(494.375000, 5.249998, "www.ocean-stunting.tk");
TextDrawLetterSize(Textdraw9, 0.449999, 1.600000);
TextDrawAlignment(Textdraw9, 1);
TextDrawColor(Textdraw9, -1);
TextDrawSetShadow(Textdraw9, 1);
TextDrawSetOutline(Textdraw9, 0);
TextDrawBackgroundColor(Textdraw9, 51);
TextDrawFont(Textdraw9, 0);
TextDrawSetProportional(Textdraw9, 1);
Thanks in advance!

Cheers.
Reply
#2

can post error lines?
Reply
#3

you sure you placed these under ongamemodeinit or onfilterscripinit
Reply
#4

Код:
//Global Textdraws:

new Text:Textdraw7;
new Text:Textdraw8;
new Text:Textdraw9;


// line 312 below:
Textdraw7 = TextDrawCreate(641.375000, 430.833312, "usebox");
TextDrawLetterSize(Textdraw7, 0.000000, 1.692597);
TextDrawTextSize(Textdraw7, -2.000000, 0.000000);
TextDrawAlignment(Textdraw7, 1);
TextDrawColor(Textdraw7, 0);
TextDrawUseBox(Textdraw7, true);
TextDrawBoxColor(Textdraw7, 102);
TextDrawSetShadow(Textdraw7, 0);
TextDrawSetOutline(Textdraw7, 0);
TextDrawFont(Textdraw7, 0);

// line 323 below:
Textdraw8 = TextDrawCreate(5.000000, 429.916717, "Welcome to Ocean Stunting");
TextDrawLetterSize(Textdraw8, 0.341246, 1.623332);
TextDrawTextSize(Textdraw8, 58.125000, -42.583385);
TextDrawAlignment(Textdraw8, 1);
TextDrawColor(Textdraw8, -1378294017);
TextDrawSetShadow(Textdraw8, 0);
TextDrawSetOutline(Textdraw8, 0);
TextDrawBackgroundColor(Textdraw8, -1378294017);
TextDrawFont(Textdraw8, 3);
TextDrawSetProportional(Textdraw8, 1);

// line 334 below:
Textdraw9 = TextDrawCreate(494.375000, 5.249998, "www.ocean-stunting.tk");
TextDrawLetterSize(Textdraw9, 0.449999, 1.600000);
TextDrawAlignment(Textdraw9, 1);
TextDrawColor(Textdraw9, -1);
TextDrawSetShadow(Textdraw9, 1);
TextDrawSetOutline(Textdraw9, 0);
TextDrawBackgroundColor(Textdraw9, 51);
TextDrawFont(Textdraw9, 0);
TextDrawSetProportional(Textdraw9, 1);
Reply
#5

EDIT: I got up how to fix those errors but now when I compile, I get another error, here it is.

Error:
Код:
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(310) : error 055: start of function body without function header
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(323) : error 055: start of function body without function header
C:\Users\Jaimin\Desktop\Jaimin's Files\Important Files\SA-MP\Ocean Stunting\gamemodes\NRG[V.4.0].pwn(336) : error 055: start of function body without function header
CODE:
Код:
// line 310 below:
{
Textdraw7 = TextDrawCreate(641.375000, 430.833312, "usebox");
TextDrawLetterSize(Textdraw7, 0.000000, 1.692597);
TextDrawTextSize(Textdraw7, -2.000000, 0.000000);
TextDrawAlignment(Textdraw7, 1);
TextDrawColor(Textdraw7, 0);
TextDrawUseBox(Textdraw7, true);
TextDrawBoxColor(Textdraw7, 102);
TextDrawSetShadow(Textdraw7, 0);
TextDrawSetOutline(Textdraw7, 0);
TextDrawFont(Textdraw7, 0);
}
// line 323 below:
{
Textdraw8 = TextDrawCreate(5.000000, 429.916717, "Welcome to Ocean Stunting");
TextDrawLetterSize(Textdraw8, 0.341246, 1.623332);
TextDrawTextSize(Textdraw8, 58.125000, -42.583385);
TextDrawAlignment(Textdraw8, 1);
TextDrawColor(Textdraw8, -1378294017);
TextDrawSetShadow(Textdraw8, 0);
TextDrawSetOutline(Textdraw8, 0);
TextDrawBackgroundColor(Textdraw8, -1378294017);
TextDrawFont(Textdraw8, 3);
TextDrawSetProportional(Textdraw8, 1);
}
// line 336 below:
{
Textdraw9 = TextDrawCreate(494.375000, 5.249998, "www.ocean-stunting.tk");
TextDrawLetterSize(Textdraw9, 0.449999, 1.600000);
TextDrawAlignment(Textdraw9, 1);
TextDrawColor(Textdraw9, -1);
TextDrawSetShadow(Textdraw9, 1);
TextDrawSetOutline(Textdraw9, 0);
TextDrawBackgroundColor(Textdraw9, 51);
TextDrawFont(Textdraw9, 0);
TextDrawSetProportional(Textdraw9, 1);
}
Reply
#6

why you giving
{

}

brackets?
Reply
#7

I just realized that it is not possible to solve it unless you all can see the whole source, anyways thanks to those who tried to help.

FIXED!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)