SS13 for experienced programmers: Difference between revisions
Jump to navigation
Jump to search
SS13 for experienced programmers (view source)
Revision as of 19:46, 2 June 2014
, 19:46, 2 June 2014→Syntax
imported>Demyelination (→Area) |
imported>Rockdtben (→Syntax) |
||
Line 12: | Line 12: | ||
i2 | i2 | ||
i3 | i3 | ||
is the same as | is the same as | ||
/obj | /obj | ||
var/i1 | var/i1 | ||
Line 21: | Line 21: | ||
/obj/var/i2 | /obj/var/i2 | ||
/obj/var/i3 | /obj/var/i3 | ||
For this project use the following layout. (This layout makes searching for variable and proc definitions easier.) | |||
/obj | |||
var/i1 | |||
var/i2 | |||
var/i3 | |||
/obj/proc/test() | |||
var/a = 5 | |||
return a + i1 | |||
/obj/del() | |||
return i1 | |||
*This guide uses the word 'object' for any defined type (see [[#Variable types|Variable types]]) and the word 'obj' for derivatives of atom/obj, which are all objects which can be placed on the map. | *This guide uses the word 'object' for any defined type (see [[#Variable types|Variable types]]) and the word 'obj' for derivatives of atom/obj, which are all objects which can be placed on the map. | ||
*This guide uses the word 'AI controlled' for behavior to do with an [[AI]] player controlling an item. The term 'Game controlled' is used when refering to behavior which the script itself determins (Usually called AI controlled creatures or NPCs) | *This guide uses the word 'AI controlled' for behavior to do with an [[AI]] player controlling an item. The term 'Game controlled' is used when refering to behavior which the script itself determins (Usually called AI controlled creatures or NPCs) |