[Help] How to mulipulate different size arrays in one method?
#1

I am trying to make a number of location on the map where you can change your skin in-game, but my method wont work cause i can't send it more than one array when they have different sizes without saying each array name. Anyone know how to do this? or is there even a way?
Reply
#2

Surely you could just link it to one array, or do i not understand what you mean?
Reply
#3

Quote:
Originally Posted by funky1234
Посмотреть сообщение
Surely you could just link it to one array, or do i not understand what you mean?
well i tryed linking it to "ArrayName[]", in the method head, but it kept giving me errors, tried defining the larges ammount of contents it would have and the head worked but when i tried to actually use it it failed. these all failed these are examples.

--------------------------------------
Quote:

M = Mens
W = Womens

stock UpDownChange(playerid, pickupid, ArrayName_M[], ArrayName_W[],EnterCoordx,EnterCoordy,EnterCoordz,DestCoordx,De stCoordy,DestCoordz,DestCoordr){
}

//-------------------------------------------------------------------------------------------------------------
//UpDownChange(playerid, pickupid, ArrayName_M[115],ArrayName_W[46],EnterCoordx,EnterCoordy,EnterCoordz,DestCoordx,De stCoordy,DestCoordz) <--------- this worked the rest failed
//UpDownChange(playerid, pickupid, ArrayName_M[],ArrayName_W[],EnterCoordx,EnterCoordy,EnterCoordz,DestCoordx,De stCoordy,DestCoordz)

UpDownChange(playerid,BeachChange,BEACH_M[7],BEACH_W[4],674.3905,-1867.2963,5.4609,674.3905,-1867.2963,5.4609,0.3819);
UpDownChange(playerid,BeachChange2,BEACH_M[],BEACH_W[],375.0468,-2065.9121,10.6953,375.0468,-2065.9121,10.6953,180.9464);
UpDownChange(playerid,BeachChange3,BEACH_M[],BEACH_W[],377.0112,-2065.9045,10.6953,377.0112,-2065.9045,10.6953,180.0064);
UpDownChange(playerid,FighterChange,FIGHTERS[],FIGHTERS[],756.2354,9.0861,1000.7003,756.2354,9.0861,1000.70 03,83.5466);

Quote:

C:\Program Files\Rockstar Games\GTA San andreas\gamemodes\test.pwn(581) : error 047: array sizes do not match, or destination array is too small
C:\Program Files\Rockstar Games\GTA San andreas\gamemodes\test.pwn(582) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San andreas\gamemodes\test.pwn(583) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San andreas\gamemodes\test.pwn(584) : err
or 029: invalid expression, assumed zero
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


4 Errors.
when no size for method head i get
C:\Program Files\Rockstar Games\GTA San andreas\gamemodes\test.pwn(581) : warning 213: tag mismatch

Or if you happen to know the format that will let me use the method, how to send it that would work too. clueless i tried every taking hours no result, couldn't find a manual on exactly what i was trying to do.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)