House Bug
#1

Hey guys.. Hopefully you guys can help me solve this:

Error I get:
Код:
C:\Users\Gabriel Vasvari\Desktop\Blueberry Roleplay\Script\gamemodes\roleplay.pwn(532) : error 017: undefined symbol "HouseLabel"
C:\Users\Gabriel Vasvari\Desktop\Blueberry Roleplay\Script\gamemodes\roleplay.pwn(532) : warning 215: expression has no effect
C:\Users\Gabriel Vasvari\Desktop\Blueberry Roleplay\Script\gamemodes\roleplay.pwn(532) : error 001: expected token: ";", but found "]"
C:\Users\Gabriel Vasvari\Desktop\Blueberry Roleplay\Script\gamemodes\roleplay.pwn(532) : error 029: invalid expression, assumed zero
C:\Users\Gabriel Vasvari\Desktop\Blueberry Roleplay\Script\gamemodes\roleplay.pwn(532) : fatal error 107: too many error messages on one line

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


4 Errors.
The Lines, Starting with line 532 Onwards:
Код:
			HouseLabel[h] = CreateDynamic3DTextLabel(labeltext, COLOUR_GREEN, hInfo[h][CPOutX], hInfo[h][CPOutY], hInfo[h][CPOutZ]+0.7, TEXTLABEL_DISTANCE, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, TEXTLABEL_TESTLOS, hInfo[h][SpawnWorld], hInfo[h][SpawnInterior], -1, TEXTLABEL_DISTANCE);
            if(isnull(hIntInfo[hInfo[h][HouseInterior]][IntName]))
			{
			    hInfo[h][HouseInterior] = DEFAULT_H_INTERIOR;
			    file = INI_Open(HouseFile(h));
			    INI_WriteInt(file, "HouseInterior", DEFAULT_H_INTERIOR);
			    INI_Close(file);
			}
			Iter_Add(Houses, h);
		    hcount++;
		}
	}
Thank you!
Reply
#2

It says it in the errors. You didn't define "HouseLabel". It might look something like:
pawn Код:
new HouseLabel[MAX_HOUSES];
Reply
#3

You need define HouseLabel new Text3D:HouseLabel[500];

replace 500 for your ammount houses
Reply
#4

Код:
new Iterator:Houses<MAX_HOUSES>, Text3D:HouseLabel[MAX_HOUSES], Float:X, Float:Y, Float:Z, Float:Angle;
Reply
#5

hydewhyd - Still doesn't work when I replaces MAX_HOUSES with 500 :[
Reply
#6

new HouseLabel[500];

try this on top of the script
Reply
#7

you sure you add it like that?
PHP код:
            new Text3D:HouseLabel[500];
            
HouseLabel[h] = CreateDynamic3DTextLabel(labeltextCOLOUR_GREENhInfo[h][CPOutX], hInfo[h][CPOutY], hInfo[h][CPOutZ]+0.7TEXTLABEL_DISTANCEINVALID_PLAYER_IDINVALID_VEHICLE_IDTEXTLABEL_TESTLOShInfo[h][SpawnWorld], hInfo[h][SpawnInterior], -1TEXTLABEL_DISTANCE);
            if(
isnull(hIntInfo[hInfo[h][HouseInterior]][IntName]))
            {
                
hInfo[h][HouseInterior] = DEFAULT_H_INTERIOR;
                
file INI_Open(HouseFile(h));
                
INI_WriteInt(file"HouseInterior"DEFAULT_H_INTERIOR);
                
INI_Close(file);
            }
            
Iter_Add(Housesh);
            
hcount++;
        }
    } 
NOTE:
Код:
new Text3D:HouseLabel[500];
has copyed from our friend lol [ hydewhyd ]
Reply
#8

new Text3D:HouseLabel[MAX_HOUSES];

on the top of your script (news, enums)....
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)