On a sidenote if i need help with code do i post here or general help?
i would say the thread best suited for coding talk would be http://psx-scene.com/forums/f276/%5B...cripts-102230/, because this is a release thread and general help is for general stuff (e.g. how to install scripts)
Has anyone figured out how to properly use the native START_NEW_SCRIPT_WITH_ARGS, right now I can only get it to pass one argument yet there is a param in there that states how many parameters you are passing, but it just doesnt seem to work. I tried to create and array and mess with the param count parameter which failed, then try with a struct but it just doesnt load the script. I dont know if you may need more script flags active but there seems to be very little documentation on this
(i like bolding text lol)
It looks like a struct is passed on everything with multiple args, but I could be wrong I get pretty confused looking through decompiled scripts. This is from brucie1.sco
void sub_935d(var0, var1, var2, var3, var4, var5)
auto var8, var9, var10, var11, var12, var13, var14, var15, var16, var17, var18, var19, var20, var21, var22, var23, var24, var25, var26, var27, var28, var29, var30, var31, var32, var33, var34, var35, var36, var37, var38, var39, var40, var41, var42, var43, var44;
var8.v8 = 5;
var38 = var8.v8;
var8.v3 = var0;
if (*(var1) > var38)
SCRIPT_ASSERT("TELL SIMON END CALL ARRAY SIZE NEEDS INCREASING");
var37 = 0;
while (var37 <= (*(var1) - 1))
var8.v8[var37 * 4].v0 = (*var1)[var37 * 4].v0;
var8.v8[var37 * 4].v1 = (*var1)[var37 * 4].v1;
var8.v8[var37 * 4].v2 = (*var1)[var37 * 4].v2;
var8.v8[var37 * 4].v3 = (*var1)[var37 * 4].v3;
var37 = var37 + 1;
if (*(var1) < var38)
strcpy(&(var8.v8[*(var1) * 4]), 16, "END");
strcpy(&(var8.v4), 16, var2);
var8.v0 = var3;
var8.v1 = var4;
var8.v2 = var5;
G = 1;
G = START_NEW_SCRIPT_WITH_ARGS("SPcellphoneEndCall", &var8, 29, 1024);
SCRIPT_ASSERT("MAKE_END_OF_MISSION_CALL() has been called more than once, might be in a loop");
I'm not sure if you can get away with a hex editing, but the script flags appear to be unencrypted and at 0x10 in the sco.
No need to worry about editing flags, i have created a little program that runs off a cmd line and lets me choose what flags i want and change the sco signature to 0x00000000 (you'd understand why thats important if your modding on pc, the issue isnt there on console) just after i compile. The problem is i dont know what the flags need to be, but that little find may suggest flags represent how many arguments should get passed into the script. Still gotta look into the spcellphone.sco and see if its flags are 0x1D000000 which would be 29 and also see how its local variables are stored
What I did was use "windows grep" to search for that native within the pack of decompiled pc scripts that is linked in the scocl thread on gtaforums (link seems to be down at the moment). That's been fairly handy for digging for info on unknown natives.
If you need the decompiled pack iv had on my medifire for awhile heres a link.
plss help me i dont know how i mus do it :S