byond - Modules - TypesVar Details - Proc Details

alien cocoon

Vars

chosen_candidateThe mob picked as a candidate to be the King
hatchedWhether the cocoon has hatched
hive_numberThe hive associated with this cocoon
rolling_candidatesIs currently rolling candidates
timerCurrent running timer
votesVoting for King

Procs

animate_hatch_kingCauses the cocoon to change visually for hatching and initiates the next timer.
announce_halfwayCauses the halfway announcements and initiates the next timer.
cast_voteTallies up votes by asking the passed candidate who they wish to vote for King.
check_pylonsCallback for a repeating 10s timer to ensure both pylons are active (otherwise delete) and counts the number of marines groundside (would cause hatching to expedite).
hatch_kingActually hatches the King transferring the candidate into the spawned mob and initiates the next timer.
is_candidate_validReturns TRUE is the candidate passed is valid: Returns TRUE is the candidate passed is valid: Has client, not facehugger, not lesser drone, not banished, and conditionally on playtime.
remove_ob_protectionThe final step in the cocoon sequence: Resets pylon protection levels
roll_candidatesFinalizes the vote for King opting to use a series of fallbacks in case a candidate declines.
start_growingCauses the cocoon to change visually for growing and initiates the next timer.
start_hatchingStarts the hatching in one minute, otherwise immediately if expedited
start_voteInitiates a vote that will end in 20 seconds to vote for the King. Hatching will then begin in 1 minute unless expedited.
try_roll_candidateReturns TRUE if a valid candidate accepts a TGUI alert asking them to be King.

Var Details

chosen_candidate

The mob picked as a candidate to be the King

hatched

Whether the cocoon has hatched

hive_number

The hive associated with this cocoon

rolling_candidates

Is currently rolling candidates

timer

Current running timer

votes

Voting for King

Proc Details

animate_hatch_king

Causes the cocoon to change visually for hatching and initiates the next timer.

announce_halfway

Causes the halfway announcements and initiates the next timer.

cast_vote

Tallies up votes by asking the passed candidate who they wish to vote for King.

Arguments:

check_pylons

Callback for a repeating 10s timer to ensure both pylons are active (otherwise delete) and counts the number of marines groundside (would cause hatching to expedite).

hatch_king

Actually hatches the King transferring the candidate into the spawned mob and initiates the next timer.

is_candidate_valid

Returns TRUE is the candidate passed is valid: Returns TRUE is the candidate passed is valid: Has client, not facehugger, not lesser drone, not banished, and conditionally on playtime.

Arguments:

remove_ob_protection

The final step in the cocoon sequence: Resets pylon protection levels

roll_candidates

Finalizes the vote for King opting to use a series of fallbacks in case a candidate declines.

First is a vote where the first and or second top picked is asked. Then all other living xenos meeting the playtime requirement are asked. Then all xeno observer candidates meeting the playtime requirement are asked. Then all other living xenos not meeting the playtime requirement are asked. Then all other xeno observer candidates not meeting the playtime requirement are asked. Then finally if after all that, the search is given up and will ultimately result in a freed King mob.

Arguments:

start_growing

Causes the cocoon to change visually for growing and initiates the next timer.

start_hatching

Starts the hatching in one minute, otherwise immediately if expedited

start_vote

Initiates a vote that will end in 20 seconds to vote for the King. Hatching will then begin in 1 minute unless expedited.

try_roll_candidate

Returns TRUE if a valid candidate accepts a TGUI alert asking them to be King.

Arguments: