CorsixTH Lua Documentation

Patient Class

A `Humanoid` who is in the hospital for diagnosis and/or treatment.

Declared on: line 21 of Lua/entities/patient.lua.
Inheritance: Patient » Humanoid » Entity

Method Index

Member Index

(*) only used in superclass methods
function Patient:Patient(...)

Parameters:

NameTypeDescription
... ? ?

Declared on: line 24 of Lua/entities/patient.lua.

function Patient:addToTreatmentHistory(room)

Parameters:

NameTypeDescription
room ? ?

Declared on: line 842 of Lua/entities/patient.lua.

function Patient:afterLoad(old, new)

Parameters:

NameTypeDescription
old ? ?
new ? ?

Overrides: Humanoid:afterLoad.
Declared on: line 932 of Lua/entities/patient.lua.

function Patient:canPeeOrPuke(current)

Parameters:

NameTypeDescription
current ? ?

Declared on: line 244 of Lua/entities/patient.lua.

function Patient:completeDiagnosticStep(room)

Updates the patients diagnostic progress based on the doctors skill called when they are done using a diagnosis room

Parameters:

NameTypeDescription
room ? ?

Declared on: line 116 of Lua/entities/patient.lua.

function Patient:falling()

animations for when there is an earth quake

Declared on: line 248 of Lua/entities/patient.lua.

function Patient:goHome(cured)

Parameters:

NameTypeDescription
cured ? ?

Declared on: line 426 of Lua/entities/patient.lua.

function Patient:modifyDiagnosisProgress(incrementValue)

Modifies the diagnosis progress of a patient. incrementValue can be either positive or negative.

Parameters:

NameTypeDescription
incrementValue ? ?

Declared on: line 103 of Lua/entities/patient.lua.

function Patient:notifyNewObject(id)

As of now each time a bench is placed the world notifies all patients in the vicinity through this function.

Parameters:

NameTypeDescription
id ? ?

Overrides: Entity:notifyNewObject.
Declared on: line 821 of Lua/entities/patient.lua.

function Patient:onClick(ui, button)

Parameters:

NameTypeDescription
ui ? ?
button ? ?

Overrides: Humanoid:onClick.
Declared on: line 34 of Lua/entities/patient.lua.

function Patient:setDiagnosed(diagnosed)

Parameters:

NameTypeDescription
diagnosed ? ?

Declared on: line 87 of Lua/entities/patient.lua.

function Patient:setDiagnosisProgress(progress)

Sets the value of the diagnosis progress.

Parameters:

NameTypeDescription
progress ? ?

Declared on: line 97 of Lua/entities/patient.lua.

function Patient:setDisease(disease)

Parameters:

NameTypeDescription
disease ? ?

Declared on: line 50 of Lua/entities/patient.lua.

function Patient:setHospital(hospital)

Parameters:

NameTypeDescription
hospital ? ?

Overrides: Humanoid:setHospital.
Declared on: line 146 of Lua/entities/patient.lua.

function Patient:setTile(x, y)

Called each time the patient moves to a new tile.

Parameters:

NameTypeDescription
x ? ?
y ? ?

Overrides: Entity:setTile.
Declared on: line 795 of Lua/entities/patient.lua.

function Patient:tickDay()

This function handles changing of the different attributes of the patient. For example if thirst gets over a certain level (now: 0.7), the patient tries to find a drinks machine nearby.

Overrides: Humanoid:tickDay.
Declared on: line 464 of Lua/entities/patient.lua.

function Patient:updateDynamicInfo(action_string)

Parameters:

NameTypeDescription
action_string ? ?

Declared on: line 856 of Lua/entities/patient.lua.

function Patient:updateMessage(choice)

Update availability of a choice in message owned by this patient, if any

Parameters:

NameTypeDescription
choice string The choice that needs updating (currently "research" or "guess_cure").

Declared on: line 893 of Lua/entities/patient.lua.

Page generated on Sat Feb 07, 2015 at 18:38:28 by LDocGen.