Leeg Posted April 6, 2017 Share Posted April 6, 2017 (edited) I can do this: if (!getarg(1)) set getarg(1), [email protected][0]; But I can't do this: if (!getarg(1)) getarg(1) = [email protected][0]; parse_line: expected ';' Intended behaviour? I thought 'set' was no longer needed in any context. Edited April 6, 2017 by Leeg Quote Link to comment Share on other sites More sharing options...
0 Daegaladh Posted April 6, 2017 Share Posted April 6, 2017 I have no idea how this even worked for you in the first place... getarg() is a function, not a variable, you just cannot set a value, it just gets the value you passed when calling the function. you need a variable [email protected] = getarg(1); if ([email protected]) [email protected] = [email protected][0]; 1 Quote Link to comment Share on other sites More sharing options...
0 Leeg Posted April 6, 2017 Author Share Posted April 6, 2017 So... it shouldn't be working with 'set' in the first place... ;D I guess I'll modify my code. 1 Quote Link to comment Share on other sites More sharing options...
0 Emistry Posted April 7, 2017 Share Posted April 7, 2017 (edited) in your case, you have to use the set() script command. if (!getarg(1)) set getarg(1), [email protected][0]; if I recall correctly this should be the case. Edited April 7, 2017 by Emistry Quote Link to comment Share on other sites More sharing options...
0 Leeg Posted April 7, 2017 Author Share Posted April 7, 2017 Yes. I already knew it works with set. Quote Link to comment Share on other sites More sharing options...
I can do this:
But I can't do this:
parse_line: expected ';'
Intended behaviour? I thought 'set' was no longer needed in any context.
Edited by LeegLink to comment
Share on other sites