Inkompetent – User talk

From Bohemia Interactive Community
Jump to navigation Jump to search
Line 9: Line 9:


Example: ''if ((nr >= 0) and {alive(someArray select nr)}) then {}:''
Example: ''if ((nr >= 0) and {alive(someArray select nr)}) then {}:''
'''Multiplayer Scripting'''
http://community.bistudio.com/wiki/6thSense.eu:EG
'''Code Optimization'''
http://community.bistudio.com/wiki/Code_Optimisation




Line 15: Line 27:


http://community.bistudio.com/wiki/6thSense.eu:CG
http://community.bistudio.com/wiki/6thSense.eu:CG
'''Programming standards and suggestions'''
http://forums.bistudio.com/showthread.php?115836-Some-advises

Revision as of 14:59, 13 June 2012

Gathered know-how

Proper use of IF-function:

Only ever use one single check per IF-function, because SQF doesn't do lazy evaluations. ALL of the checks in an IF-clause will be tested, even if the first one and all before the current tested one has failed.


NOTE EXCEPTION: Code can be used for lazy evaluation since build 93640.

Example: if ((nr >= 0) and {alive(someArray select nr)}) then {}:


Multiplayer Scripting

http://community.bistudio.com/wiki/6thSense.eu:EG


Code Optimization

http://community.bistudio.com/wiki/Code_Optimisation


CONFIGS

http://community.bistudio.com/wiki/6thSense.eu:CG


Programming standards and suggestions

http://forums.bistudio.com/showthread.php?115836-Some-advises