dimension_theme
Datum which describes a theme and replaces turfs and objects in specified locations to match that theme
Vars | |
icon | An icon to display to represent the theme |
---|---|
icon_state | Icon state to use to represent the theme |
material | Typepath of custom material to use for objects. |
name | Human readable name of the theme |
random_spawn_chance | Prob of placing a random spawn in a completely open turf |
random_spawns | List of random spawns to place in completely open turfs |
replace_floors | Weighted list of turfs to replace the floor with. |
replace_objs | List of weighted lists for object replacement. Key is an original typepath, value is a weighted list of typepaths to replace it with. |
replace_walls | Typepath of turf to replace walls with. |
replace_window | Typepath of full-size windows which will replace existing ones These need to be separate from replace_objs because we don't want to replace dir windows with full ones and they share typepath |
sound | Sound to play when transforming a tile |
window_colour | Colour to recolour windows with, replaced by material colour if material was specified. |
Procs | |
apply_materials | Applies a new custom material to the contents of a provided turf. |
apply_theme | Applies themed transformation to the provided turf. |
apply_theme_to_list_of_turfs | Applies the transformation to a list of turfs, ensuring a sound is only played every few turfs to reduce noice spam |
can_convert | Returns true if you actually can transform the provided turf. |
get_replacement_object_typepath | Returns the typepath of an object to replace the provided object. |
permit_replace_material | Returns true if the provided object can have its material modified. |
replace_object | Replaces the provided object with a different one. |
replace_turf | Replaces the provided turf with a different one. |
transform_floor | Replaces the provided floor turf with a different one. |
transform_window | Replaces a window with a different window and recolours it. This needs its own function because we only want to replace full tile windows. |
Var Details
icon
An icon to display to represent the theme
icon_state
Icon state to use to represent the theme
material
Typepath of custom material to use for objects.
name
Human readable name of the theme
random_spawn_chance
Prob of placing a random spawn in a completely open turf
random_spawns
List of random spawns to place in completely open turfs
replace_floors
Weighted list of turfs to replace the floor with.
replace_objs
List of weighted lists for object replacement. Key is an original typepath, value is a weighted list of typepaths to replace it with.
replace_walls
Typepath of turf to replace walls with.
replace_window
Typepath of full-size windows which will replace existing ones These need to be separate from replace_objs because we don't want to replace dir windows with full ones and they share typepath
sound
Sound to play when transforming a tile
window_colour
Colour to recolour windows with, replaced by material colour if material was specified.
Proc Details
apply_materials
Applies a new custom material to the contents of a provided turf.
Arguments
- affected_turf - Turf to transform.
apply_theme
Applies themed transformation to the provided turf.
Arguments
- affected_turf - Turf to transform.
- skip_sound - If the sound shouldn't be played.
- show_effect - if the temp visual effect should be shown.
apply_theme_to_list_of_turfs
Applies the transformation to a list of turfs, ensuring a sound is only played every few turfs to reduce noice spam
Arguments
- list/turf/all_turfs - List of turfs to transform.
can_convert
Returns true if you actually can transform the provided turf.
Arguments
- affected_turf - Turf to transform.
get_replacement_object_typepath
Returns the typepath of an object to replace the provided object.
Arguments
- object - Object to transform.
permit_replace_material
Returns true if the provided object can have its material modified.
Arguments
- object - Object to transform.
replace_object
Replaces the provided object with a different one.
Arguments
- object - Object to replace.
replace_turf
Replaces the provided turf with a different one.
Arguments
- affected_turf - Turf to transform.
transform_floor
Replaces the provided floor turf with a different one.
Arguments
- affected_floor - Floor turf to transform.
transform_window
Replaces a window with a different window and recolours it. This needs its own function because we only want to replace full tile windows.
Arguments
- object - Object to transform.