Understanding SS13 code: Difference between revisions

Jump to navigation Jump to search
m
no edit summary
imported>Cheridan
mNo edit summary
 
Line 76: Line 76:
<br>[http://www.byond.com/members/?command=reference&path=mob%2Fvar Mob vars]
<br>[http://www.byond.com/members/?command=reference&path=mob%2Fvar Mob vars]


===== Direction (dir) var =====
=====Direction (dir) var=====
[http://www.byond.com/members/?command=reference&path=atom%2Fvar%2Fdir reference]
[http://www.byond.com/members/?command=reference&path=atom%2Fvar%2Fdir reference]


Line 88: Line 88:
'''Southwest:''' 10 (2 + 8)<br>
'''Southwest:''' 10 (2 + 8)<br>


They are numbered like this because dir uses the 'bitflag' methodology. You can read more about bitflags [[Binary_flags|here.]]  It is defined in binary, so...
They are numbered like this because dir uses the 'bitflag' methodology. It is defined in binary, so...


'''0001''' is north<br>
'''0001''' is north<br>
Line 97: Line 97:
Combining these numbers yields north-east (0101), north-west (1001), south-east (0110) and south-west (1010). Tho other combinations (east-west(1100), north-south (0011), north-east-west (1101) and such) are possible for special uses. Smoothwall code is an example.
Combining these numbers yields north-east (0101), north-west (1001), south-east (0110) and south-west (1010). Tho other combinations (east-west(1100), north-south (0011), north-east-west (1101) and such) are possible for special uses. Smoothwall code is an example.


===== Atom vars =====
=====Atom vars=====


These apply to all /obj, /turf, /area, /mob -type objects.
These apply to all /obj, /turf, /area, /mob -type objects.
Wiki Staff
6,460

edits

Navigation menu