SA-MP Forums Archive
Inconsistent return types - 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: Inconsistent return types (/showthread.php?tid=495027)



Inconsistent return types - seanny - 15.02.2014

Hello I am getting "inconsistent return types" on my LoadFaction_data() function.

Quote:
Originally Posted by Pawn Compiler
E:\Scripting\pawno\include\progress.inc(170) : warning 217: loose indentation
E:\Scripting\pawno\include\progress.inc(172) : warning 217: loose indentation
E:\Scripting\gamemodes\hrp.pwn(2372) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2373) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2374) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2375) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2376) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2377) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2378) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2379) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2380) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2381) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2382) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2383) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2384) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2385) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2386) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2387) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2388) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2389) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2390) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2391) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2392) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2393) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2394) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2398) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2400) : error 079: inconsistent return types (array & non-array)
E:\Scripting\gamemodes\hrp.pwn(2401) : error 079: inconsistent return types (array & non-array)

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


26 Errors.
pawn Код:
forward LoadFaction_data(iIndex, name[], value[]);
public LoadFaction_data(iIndex, name[], value[])
{
    new szVar[10];
    INI_Int("Taken", FactionInfo[iIndex][fTaken]);//LINE 2372
    INI_String("Name", FactionInfo[iIndex][fName], 128);
    INI_String("ShortName", FactionInfo[iIndex][fName2], 10);
    INI_String("Rank1", FactionInfo[iIndex][fRank1], 128);
    INI_String("Rank2", FactionInfo[iIndex][fRank2], 128);
    INI_String("Rank3", FactionInfo[iIndex][fRank3], 128);
    INI_String("Rank4", FactionInfo[iIndex][fRank4], 128);
    INI_String("Rank5", FactionInfo[iIndex][fRank5], 128);
    INI_String("Rank6", FactionInfo[iIndex][fRank6], 128);
    INI_String("Rank7", FactionInfo[iIndex][fRank7], 128);
    INI_String("Rank8", FactionInfo[iIndex][fRank8], 128);
    INI_String("Rank9", FactionInfo[iIndex][fRank9], 128);
    INI_String("Rank10", FactionInfo[iIndex][fRank10], 128);
    INI_String("Rank11", FactionInfo[iIndex][fRank11], 128);
    INI_String("Rank12", FactionInfo[iIndex][fRank12], 128);
    INI_String("Rank13", FactionInfo[iIndex][fRank13], 128);
    INI_String("Rank14", FactionInfo[iIndex][fRank14], 128);
    INI_String("Rank15", FactionInfo[iIndex][fRank15], 128);
    INI_String("Rank16", FactionInfo[iIndex][fRank16], 128);
    INI_String("Rank17", FactionInfo[iIndex][fRank17], 128);
    INI_String("Rank18", FactionInfo[iIndex][fRank18], 128);
    INI_String("Rank19", FactionInfo[iIndex][fRank19], 128);
    INI_String("Rank20", FactionInfo[iIndex][fRank20], 128);
    for(new i = 0; i < 8; i++)
    {
        format(szVar, sizeof szVar, "Skin%d", i);
        INI_Int(szVar, FactionInfo[iIndex][fSkins][i]);
    }
    INI_Int("MaxSkins", FactionInfo[iIndex][fMaxSkins]);
    INI_String("Leader", FactionInfo[iIndex][fLeader], 128);//LINE 2401
    INI_Int("Type", FactionInfo[iIndex][fType]);
    INI_Int("Siren", FactionInfo[iIndex][fSiren]);
    INI_Int("Bank", FactionInfo[iIndex][fBank]);
    INI_Int("MaxRanks", FactionInfo[iIndex][fMaxRanks]);
    INI_String("MOTD", FactionInfo[iIndex][fMOTD], 128);
    INI_Int("Closed", FactionInfo[iIndex][fClosed]);
    for(new i = 1; i < 21; i++)
    {
        format(szVar, sizeof szVar, "Pay%d", i);
        INI_Int(szVar, FactionInfo[iIndex][fPay][i]);
    }
    INI_Float("LockerX", FactionInfo[iIndex][fLockerX]);
    INI_Float("LockerY", FactionInfo[iIndex][fLockerY]);
    INI_Float("LockerZ", FactionInfo[iIndex][fLockerZ]);
    INI_Int("LockerR", FactionInfo[iIndex][fLockerVW]);
    for(new i = 1; i < 16; i++)
    {
        format(szVar, sizeof szVar, "Weapon%d", i);
        INI_Int(szVar, FactionInfo[iIndex][fLockerWeapons][i]);
    }
    for(new i = 1; i < 16; i++)
    {
        format(szVar, sizeof szVar, "WeaponAmmo%d", i);
        INI_Int(szVar, FactionInfo[iIndex][fLockerWeaponAmmo][i]);
    }
    INI_Int("Members", FactionInfo[iIndex][fMembers]);
    INI_Int("DepartmentAccess", FactionInfo[iIndex][fDeptRadioAccess]);
    INI_Int("GovAccess", FactionInfo[iIndex][fGovAccess]);
    INI_Int("SpikeStrips", FactionInfo[iIndex][fSpikeStrips]);
    INI_Int("RoadBlocks", FactionInfo[iIndex][fRoadBlocks]);
    for(new i = 1; i < 5; i++)
    {
        format(szVar, sizeof szVar, "Jurisdiction%d", i);
        INI_Int(szVar, FactionInfo[iIndex][fJurisdiction]);
    }
    INI_Int("Strikes", FactionInfo[iIndex][fStrikes]);
    for(new i = 1; i < 5; i++)
    {
        format(szVar, sizeof szVar, "Division%d", i);
        INI_Int(szVar, FactionDivisionInfo[iIndex][i]);
    }
    UpdateFactionLocker(iIndex);
    return 1;
}