seethrough
A component that lets you turn an object invisible when you're standing on certain relative turfs to it, like behind a tree
Vars | |
animation_time | How long our fase in/out takes |
---|---|
clickthrough | Does this object let clicks from players its transparent to pass through it |
perimeter_reset_timer | After we somehow moved (because ss13 is godless and does not respect anything), how long do we need to stand still to feel safe to setup our "behind" area again |
relative_turf_coords | List of lists that represent relative coordinates to the source atom |
target_alpha | Which alpha do we animate towards? |
tricked_mobs | Associate list, with client = trickery_image. Track which client is being tricked with which image |
watched_turfs | A list of turfs on which we make ourself transparent |
Procs | |
Initialize | see_through_map is a define pointing to a specific map. It's basically defining the area which is considered behind. See see_through_maps.dm for a list of maps |
clear_image | Remove a screen image from a client |
dismantle_perimeter | Unrout ourselves after we somehow moved, and start a timer so we can re-restablish our behind area after standing still for a bit |
on_client_disconnect | Image is removed when they log out because client gets deleted, so drop the mob reference |
on_entered | Someone entered one of our tiles, so sent an override overlay and a cute animation to make us fade out a bit |
on_exited | Remove the screen object and make us appear solid to the client again |
setup_perimeter | Loop through a list with relative coordinate lists to mark those tiles and hide our parent when someone enters those tiles |
trick_mob | Apply the trickery image and animation |
Var Details
animation_time
How long our fase in/out takes
clickthrough
Does this object let clicks from players its transparent to pass through it
perimeter_reset_timer
After we somehow moved (because ss13 is godless and does not respect anything), how long do we need to stand still to feel safe to setup our "behind" area again
relative_turf_coords
List of lists that represent relative coordinates to the source atom
target_alpha
Which alpha do we animate towards?
tricked_mobs
Associate list, with client = trickery_image. Track which client is being tricked with which image
watched_turfs
A list of turfs on which we make ourself transparent
Proc Details
Initialize
see_through_map is a define pointing to a specific map. It's basically defining the area which is considered behind. See see_through_maps.dm for a list of maps
clear_image
Remove a screen image from a client
dismantle_perimeter
Unrout ourselves after we somehow moved, and start a timer so we can re-restablish our behind area after standing still for a bit
on_client_disconnect
Image is removed when they log out because client gets deleted, so drop the mob reference
on_entered
Someone entered one of our tiles, so sent an override overlay and a cute animation to make us fade out a bit
on_exited
Remove the screen object and make us appear solid to the client again
setup_perimeter
Loop through a list with relative coordinate lists to mark those tiles and hide our parent when someone enters those tiles
trick_mob
Apply the trickery image and animation