Daedalus Dock - Modules - TypesVar Details - Proc Details

lift_master

coordinate and control movement across linked industrial_lift's. allows moving large single multitile platforms and many 1 tile platforms. also is capable of linking platforms across linked z levels

Vars

allowed_travel_directionswhat directions we're allowed to move
controls_lockedif true, the lift cannot be manually moved.
create_multitile_platformtaken from our lift platforms. if true we go through each z level of platforms and attempt to make the lowest left corner platform into one giant multitile object the size of all other platforms on that z level.
ignored_smashthroughsTypepath list of what to ignore smashing through, controls all lifts
lift_idlift_id taken from our base lift platform, used to put us into GLOB.active_lifts_by_type
lift_platformsthe lift platforms we consider as part of this lift. ordered in order of lowest z level to highest z level after init. (the sorting algorithm sucks btw)
multitile_platformwhether the lift handled by this lift_master datum is multitile as opposed to nxm platforms per z level
specific_lift_idoverridable ID string to link control units to this specific lift_master datum. created by placing a lift id landmark object somewhere on the tram, if its anywhere on the tram we'll find it in init and set this to whatever it specifies
z_sortedlift platforms have already been sorted in order of z level.

Procs

Check_lift_moveCheck destination turfs
MoveLiftMoves the lift UP or DOWN, this is what users invoke with their hand. This is a SAFE proc, ensuring every part of the lift moves SANELY. It also locks controls for the (miniscule) duration of the movement, so the elevator cannot be broken by spamming. Arguments: going - UP or DOWN directions, where the lift should go. Keep in mind by this point checks of whether it should go up or down have already been done. user - Whomever made the lift movement.
MoveLiftHorizontalMoves the lift, this is what users invoke with their hand. This is a SAFE proc, ensuring every part of the lift moves SANELY. It also locks controls for the (miniscule) duration of the movement, so the elevator cannot be broken by spamming.
Rebuild_lift_plaformCollect all bordered platforms via a simple floodfill algorithm. allows multiz trams because its funny
check_for_landmarkscheck for any landmarks placed inside the locs of the given lift_platform
create_multitile_platform_for_z_levelgoes through all platforms in the given list and finds the one in the lower left corner
get_platforms_on_levelreturns all industrial_lifts associated with this tram on the given z level or given atoms z level
order_platforms_by_z_levelorders the lift platforms in order of lowest z level to highest z level.
reset_lift_contentsresets the contents of all platforms to their original state in case someone put a bunch of shit onto the tram. intended to be called by admins. passes all arguments to reset_contents() for each of our platforms.
return_closest_platform_toreturns the closest lift to the specified atom, prioritizing lifts on the same z level. used for comparing distance
set_controlsSets all lift parts's controls_locked variable. Used to prevent moving mid movement, or cooldowns.
set_info_from_id_landmarkset vars and such given an overriding lift_id landmark

Var Details

allowed_travel_directions

what directions we're allowed to move

controls_locked

if true, the lift cannot be manually moved.

create_multitile_platform

taken from our lift platforms. if true we go through each z level of platforms and attempt to make the lowest left corner platform into one giant multitile object the size of all other platforms on that z level.

ignored_smashthroughs

Typepath list of what to ignore smashing through, controls all lifts

lift_id

lift_id taken from our base lift platform, used to put us into GLOB.active_lifts_by_type

lift_platforms

the lift platforms we consider as part of this lift. ordered in order of lowest z level to highest z level after init. (the sorting algorithm sucks btw)

multitile_platform

whether the lift handled by this lift_master datum is multitile as opposed to nxm platforms per z level

specific_lift_id

overridable ID string to link control units to this specific lift_master datum. created by placing a lift id landmark object somewhere on the tram, if its anywhere on the tram we'll find it in init and set this to whatever it specifies

z_sorted

lift platforms have already been sorted in order of z level.

Proc Details

Check_lift_move

Check destination turfs

MoveLift

Moves the lift UP or DOWN, this is what users invoke with their hand. This is a SAFE proc, ensuring every part of the lift moves SANELY. It also locks controls for the (miniscule) duration of the movement, so the elevator cannot be broken by spamming. Arguments: going - UP or DOWN directions, where the lift should go. Keep in mind by this point checks of whether it should go up or down have already been done. user - Whomever made the lift movement.

MoveLiftHorizontal

Moves the lift, this is what users invoke with their hand. This is a SAFE proc, ensuring every part of the lift moves SANELY. It also locks controls for the (miniscule) duration of the movement, so the elevator cannot be broken by spamming.

Rebuild_lift_plaform

Collect all bordered platforms via a simple floodfill algorithm. allows multiz trams because its funny

check_for_landmarks

check for any landmarks placed inside the locs of the given lift_platform

create_multitile_platform_for_z_level

goes through all platforms in the given list and finds the one in the lower left corner

get_platforms_on_level

returns all industrial_lifts associated with this tram on the given z level or given atoms z level

order_platforms_by_z_level

orders the lift platforms in order of lowest z level to highest z level.

reset_lift_contents

resets the contents of all platforms to their original state in case someone put a bunch of shit onto the tram. intended to be called by admins. passes all arguments to reset_contents() for each of our platforms.

Arguments:

return_closest_platform_to

returns the closest lift to the specified atom, prioritizing lifts on the same z level. used for comparing distance

set_controls

Sets all lift parts's controls_locked variable. Used to prevent moving mid movement, or cooldowns.

set_info_from_id_landmark

set vars and such given an overriding lift_id landmark