/tg/ Station 13 - Modules - TypesVar Details - Proc Details

crayon

Vars

actually_paintsIf set to false, this just applies a chemical and cannot paint symbols
all_drawablesCombined lists
can_change_colourIf the user can toggle the colour, a la vanilla spraycan
chargesNumber of times this item can be used, INFINITE_CHARGES for unlimited
charges_leftNumber of remaining charges
crayon_colorCrayon overlay to use if placed into a crayon box
drawingsList of selectable drawing options
drawtypeContains chosen symbol to draw
edibleWhether or not you can eat this. Doesn't mean it is a good idea to eat it.
expose_turfsIf true, sprayed turfs should also have the internal chemical applied to them
graffitiList of selectable graffiti options If an associated value is present, the graffiti has its own cost otherwise it'll be the default value. Ditto with the other other lists below.
graffiti_large_hList of selectable large options
has_capWhether this item has a cap that can be toggled on and off
icon_cappedIcon state to use when capped
icon_uncappedIcon state to use when uncapped
instantIf false a do_after is required to draw something, otherwise it applies immediately
is_cappedWhether the cap is currently on or off
orientedList of selectable orientable options
overlay_paint_colourIf true, a coloured overlay is applied to display the currently selected colour
paint_colorCurrent paint colour
paint_modeDictates how large of an area we cover with our paint
post_noiseWhether to play a sound after using
pre_noiseWhether to play a sound before using
randomsList of selectable random options
reagent_contentsReagents which are applied to things you use this on, or yourself if you eat it
runesList of selectable rune options
self_containedIf true, this deletes itself when empty
symbolsList of selectable symbol options
text_bufferStores buffer of text to draw, one character at a time
volume_multiplierMultiplies effect of reagent when applied to mobs or surfaces

Procs

after_eatUsed for edible component to reduce charges_left on bite.
can_use_onIs this a valid object for use_on to run on?
check_emptyWhen eating a crayon, check_empty() can be called twice producing two messages unless we check for being deleted first.
refillRefills charges_left in infinite crayons on use. Sets charges_left in infinite crayons to 100 for spawning reagents. Spawns reagents in crayons based on the amount of charges_left if not spawned yet.
set_painting_tool_colorSets painting color and updates appearance.
use_chargesReturns number of charges actually used.
use_onAttempts to color the target.

Var Details

actually_paints

If set to false, this just applies a chemical and cannot paint symbols

all_drawables

Combined lists

can_change_colour

If the user can toggle the colour, a la vanilla spraycan

charges

Number of times this item can be used, INFINITE_CHARGES for unlimited

charges_left

Number of remaining charges

crayon_color

Crayon overlay to use if placed into a crayon box

drawings

List of selectable drawing options

drawtype

Contains chosen symbol to draw

edible

Whether or not you can eat this. Doesn't mean it is a good idea to eat it.

expose_turfs

If true, sprayed turfs should also have the internal chemical applied to them

graffiti

List of selectable graffiti options If an associated value is present, the graffiti has its own cost otherwise it'll be the default value. Ditto with the other other lists below.

graffiti_large_h

List of selectable large options

has_cap

Whether this item has a cap that can be toggled on and off

icon_capped

Icon state to use when capped

icon_uncapped

Icon state to use when uncapped

instant

If false a do_after is required to draw something, otherwise it applies immediately

is_capped

Whether the cap is currently on or off

oriented

List of selectable orientable options

overlay_paint_colour

If true, a coloured overlay is applied to display the currently selected colour

paint_color

Current paint colour

paint_mode

Dictates how large of an area we cover with our paint

post_noise

Whether to play a sound after using

pre_noise

Whether to play a sound before using

randoms

List of selectable random options

reagent_contents

Reagents which are applied to things you use this on, or yourself if you eat it

runes

List of selectable rune options

self_contained

If true, this deletes itself when empty

symbols

List of selectable symbol options

text_buffer

Stores buffer of text to draw, one character at a time

volume_multiplier

Multiplies effect of reagent when applied to mobs or surfaces

Proc Details

after_eat

Used for edible component to reduce charges_left on bite.

can_use_on

Is this a valid object for use_on to run on?

check_empty

When eating a crayon, check_empty() can be called twice producing two messages unless we check for being deleted first.

Arguments:

refill

Refills charges_left in infinite crayons on use. Sets charges_left in infinite crayons to 100 for spawning reagents. Spawns reagents in crayons based on the amount of charges_left if not spawned yet.

set_painting_tool_color

Sets painting color and updates appearance.

use_charges

Returns number of charges actually used.

Arguments:

use_on

Attempts to color the target.