SA-MP Forums Archive
house help.. - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: house help.. (/showthread.php?tid=245285)



house help.. - kickflipdude - 30.03.2011

Hi, when i try to add a house for example:

pawn Код:
CreateHouse("TestHouse2", 1, 2346.872802, 692.999267, 11.460937, 266.857757, 305.001586, 999.148437, 2, 1);
I get this error:
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(5 : warning 225: unreachable code
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(5 : warning 217: loose indentation
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(63) : warning 217: loose indentation
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(77) : warning 217: loose indentation
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(82) : warning 217: loose indentation
C:\Users\Anoop\Desktop\samp03csvr_R2-2_win32\gamemodes\Server.pwn(85) : warning 209: function "CreateHouse" should return a value

Does anyone know whats wrong?

I am following :
https://sampforum.blast.hk/showthread.php?tid=118379

I didnt skip a single step, and before i add the createhouse, it compiles fine... O.o


Re: house help.. - KaleOtter - 30.03.2011

Show use the lines that gives those errors.
so line: 5-63-77-82-85


Re: house help.. - kickflipdude - 30.03.2011

Line 58:
pawn Код:
{
Line 63
pawn Код:
HouseCount ++;
Line 77:
pawn Код:
if(strlen(dini_Get("Owners.ini", Filename))) //This is to see if there is any owner.
Line 82:
pawn Код:
PickupID[ID] = CreatePickup(1273, 23, Pickupx, Pickupy, Pickupz, -1); //Creates the pickup :).
Line 85:
pawn Код:
}



Re: house help.. - KaleOtter - 30.03.2011

Well the loos indentation is easy to fix, just tabsize/outline (however it's called) your script better.
And well I cannot really see any mistakes in those lines, maybe you can show more of it...