Many errors [+REP]
#1

Hi

I am getting the following errors on my script:

PHP код:
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1143) : warning 213tag mismatch
C
:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1153) : warning 202number of arguments does not match definition
C
:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1166) : warning 213tag mismatch 
They come from this command:

Код:
(1143) 			HouseInfo[id][hOwned] = owned;;

(1153) new INI:File = INI_Open(HousePath(id));

(1166) string[84] = Create3DTextLabel(string,0xFF0000FF, x, y, z, 25.0,0);
Please help if you can.
Reply
#2

Hello!

1st problem:
PHP код:
HouseInfo[id][hOwned] = owned;; 
to
PHP код:
HouseInfo[id][hOwned] = owned
Is hOwned a string or a integer?


2nd problem:
Can you send me the function of "HousePath"?

3rd problem:
PHP код:
new stringlabel Create3DTextLabel(string,0xFF0000FFxyz25.0,0); 
Try this. Probably you have to create "stringlabel" global if you use this variable global.
Reply
#3

(1) I realised and I had set it just as you said! I was very tired when I posted this

(2)
Код:
stock HousePath()
{
    new string[128];
    format(string,sizeof(string),hPATH);
    return string;
}
(3) I tried this and it gave me a new error: [code]C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1165) : error 035: argument type mismatch (argument 1)/code]

This is the code for the entire create3dtextlabel:
Код:
new string[84];
			format(string,sizeof(string),"Owned: No \nPrice: %i",price);
			new stringlabel = Create3DTextLabel(stringlabel,0xFF0000FF, x, y, z, 25.0,0);
			HouseInfo[id][hIcon] = stringlabel;
			HouseCount++;
Thanks for getting back to me.
Reply
#4

Change :
PHP код:
new stringlabel 
To

PHP код:
new Text3D:stringlabel 
And try to :
Change :
PHP код:
stock HousePath()
{
    new 
string[128];
    
format(string,sizeof(string),hPATH);
    return 
string;

PHP код:
stock HousePath(h)
{
    new 
string[128];
    
format(string,sizeof(string),h);
    return 
string;

Reply
#5

Код:
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1166) : error 035: argument type mismatch (argument 1)
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1167) : warning 213: tag mismatch
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(3727) : error 035: argument type mismatch (argument 3)
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(3724) : warning 203: symbol is never used: "h"
Код:
1166 - Create3DTextLabel(stringlabel,0xFF0000FF, x, y, z, 25.0,0);

1167 - HouseInfo[id][hIcon] = stringlabel;

3727 - format(string,sizeof(string),h);

3724 - stock HousePath(h)
Current errors and lines
Reply
#6

2.)
PHP код:
new INI:File INI_Open(HousePath()); 
3.)
PHP код:
new string[84];
format(string,sizeof(string),"Owned: No \nPrice: %i",price);
HouseInfo[id][hIcon] = Create3DTextLabel(string,0xFF0000FFxyz25.0,0);
HouseCount++; 
Try this!
Reply
#7

Код:
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1152) : warning 202: number of arguments does not match definition
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1165) : warning 213: tag mismatch
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(3725) : error 035: argument type mismatch (argument 3)
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(3722) : warning 203: symbol is never used: "h"
Код:
1152 - new INI:File = INI_Open(HousePath());

1165 - HouseInfo[id][hIcon] = stringlabel;

3727 - format(string,sizeof(string),h);

3722 - stock HousePath(h)
It keeps making errors for some reason.
Reply
#8

What do you do there?
PHP код:
new string[84]; 
format(string,sizeof(string),"Owned: No \nPrice: %i",price); 
HouseInfo[id][hIcon] = Create3DTextLabel(string,0xFF0000FFxyz25.0,0); 
HouseCount++; 
and
PHP код:
stock HousePath() 

    new 
string[128]; 
    
format(string,sizeof(string),hPATH); 
    return 
string

Reply
#9

Quote:
Originally Posted by Mencent
Посмотреть сообщение
What do you do there?
It is a createhouse command made it with help of a tutorial, didnt copy any of it just read through and made my own.


PHP код:
C:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(1166) : warning 213tag mismatch
C
:\Users\\Desktop\games\samp scripts\Roleplay (0.3.7)\gamemodes\roleplay.pwn(3726) : error 017undefined symbol "hPath"[code]
[
code]1166 HouseInfo[id][hIcon] = Create3DTextLabel(string,0xFF0000FFxyz25.0,0);
3726 format(string,sizeof(string),hPath); //yet there is already a #define hPath at the top of the script...
#define hPATH "Houses/%s.ini" 
This is quite strange!
Reply
#10

1st problem:
You have to define hIcon like this:
PHP код:
Text3D:hIcon 
2nd problem:
What's the "%s"? The name of the player?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)