SA-MP Forums Archive
number of... - 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)
+--- Thread: number of... (/showthread.php?tid=362453)



number of... - kepa333 - 24.07.2012

hello i need help after long time.
i made house sysem.
but its bug.


PHP код:
C:\Users\MaticKepa\Desktop\samp\SFCRRPG\gamemodes\SFCRRPG.pwn(11374) : warning 202number of arguments does not match definition
C
:\Users\MaticKepa\Desktop\samp\SFCRRPG\gamemodes\SFCRRPG.pwn(17028) : warning 202number of arguments does not match definition
C
:\Users\MaticKepa\Desktop\samp\SFCRRPG\gamemodes\SFCRRPG.pwn(17032) : warning 202number of arguments does not match definition
C
:\Users\MaticKepa\Desktop\samp\SFCRRPG\gamemodes\SFCRRPG.pwn(17033) : warning 202number of arguments does not match definition
Pawn compiler 3.2.3664              Copyright 
(c1997-2006ITB CompuPhase
4 Warnings

those lines
PHP код:
        if(IsPlayerInRangeOfPoint(jHouseInfo[j][hEnterX], HouseInfo[j][hEnterY], HouseInfo[j][hEnterZ]) && GetPlayerInterior(i) == HouseInfo[j][hOutsideInt] && GetPlayerVirtualWorld(i) == HouseInfo[j][hOutsideVir])
    
dini_Get(fstring"Owner"HouseInfo[houseid][hOwner]);
    
dini_Float(fstring"HV_PosZ"HouseInfo[houseid][hVecZ]);
    
dini_Float(fstring"HV_PosA"HouseInfo[houseid][hVecA]); 



Re: number of... - Kindred - 24.07.2012

Try this:

pawn Код:
if(IsPlayerInRangeOfPoint(i, 7, HouseInfo[j][hEnterX], HouseInfo[j][hEnterY], HouseInfo[j][hEnterZ]) && GetPlayerInterior(i) == HouseInfo[j][hOutsideInt] && GetPlayerVirtualWorld(i) == HouseInfo[j][hOutsideVir])
You didn't add a range. Plus, why are you using j as the playerid? From what it looks like, you are doing a loop with the variable i, as you check i's interior/virtual world, so I changed j to i on IsPlayerInRangeOfPoint.


Re: number of... - kepa333 - 24.07.2012

EDIT: for(new j = 0; j < MAX_HOUSES; j++)

mybe u will understand it now :P


Re: number of... - Kindred - 24.07.2012

I understand, but does that work?

Of course your old code wouldn't have worked, considering you were checking if a house id was in range of the house coordinates, instead of a playerid, and you weren't checking the range.

Did it work when you compiled with what I provided?

If not, reshow all the errors, explaing what line each is on using comments (// comment here)