var/secbar = "closed"
proc
checksecbar1(var/turf/T)
if(secbar == "closed")
T.icon = 'icons2.dmi'
T.icon_state = "secbar"
T.density = 1
if(secbar == "open")
T.icon = 'icons2.dmi'
T.icon_state = "nosecbar"
T.density = 0
world
New()
..()
spawn() checksecbar1()
turf
proc
activate()
if(secbar == "closed")
return 0
if(secbar == "opened")
return
turf
securitybar
icon = 'icons2.dmi'
icon_state = "secbar"
Enter()
activate()
////////////////////////////////////////////////
I haven't created it yet where an npc modifies the var at runtime.
This coding creates run time errors constantly.
Im trying to create a coding that checks the proc every server tick so the second an npc activates the security bar. It will open or close, show the icon state and have the desired density.
ID:147333
![]() Jun 29 2004, 7:57 pm
|
|
eh.. nevermind. The process is too complicated. The activation system by vortezz was diagramed too complex for the more rookie eye to scan and learn from it. Just for thinking sake.
Here's what I was trying to do.
|
checksecbar1(var/turf/T) //you defined an argument but, you didn't input anything into it when you call the proc on world/New().