forked from Mirrors/openclonk
Add AcidDrilling title image
parent
1b76c31452
commit
18437305ca
Binary file not shown.
After Width: | Height: | Size: 48 KiB |
|
@ -135,6 +135,10 @@ func Definition(def)
|
|||
{ Name="$EjectContentsYes$", Value=true }
|
||||
] },
|
||||
} } );
|
||||
AddEvaluator("Action", "Clonk", "$DoEnergy$", "$DoEnergyHelp$", "do_energy", [def, def.EvalAct_ObjectCallInt, Global.DoEnergy], { Object={ Function="triggering_clonk" } }, { Type="proplist", Display="({{Object}}, {{Value}})", ShowFullName=true, EditorProps = {
|
||||
Object = new Evaluator.Object { Name="$Object$", EditorHelp="$DoEnergyObjectHelp$" },
|
||||
Value = new Evaluator.Integer { Name="$ValueChange$", EditorHelp="$DoEnergyValueChangeHelp$" }
|
||||
} } );
|
||||
AddEvaluator("Action", "$Script$", "$ConditionalAction$", "$ConditionalActionHelp$", "if", [def, def.EvalAct_If, "Action"], { }, { Type="proplist", Display="if({{Condition}}) {{Action}} else {{ElseAction}}", EditorProps = {
|
||||
Condition = new Evaluator.Boolean { Name="$Condition$", EditorHelp="$IfConditionHelp$", Priority=60 },
|
||||
TrueEvaluator = new Evaluator.Action { Name="$TrueEvaluator$", EditorHelp="$TrueEvaluatorHelp$", Priority=50 },
|
||||
|
@ -789,6 +793,14 @@ private func EvalAct_RemoveObject(proplist props, proplist context)
|
|||
obj->RemoveObject(props.EjectContents);
|
||||
}
|
||||
|
||||
private func EvalAct_ObjectCallInt(proplist props, proplist context, func call_fn)
|
||||
{
|
||||
var obj = EvaluateValue("Object", props.Object, context);
|
||||
if (!obj) return;
|
||||
var parameter = EvaluateValue("Integer", props.Value, context);
|
||||
obj->Call(call_fn, parameter);
|
||||
}
|
||||
|
||||
private func EvalAct_If(proplist props, proplist context, eval_type)
|
||||
{
|
||||
// Do evaluation on first pass. After that, take context value.
|
||||
|
|
|
@ -282,3 +282,8 @@ TrueEvaluator=Bedingte Aktion
|
|||
TrueEvaluatorHelp=Aktion, die nur dann ausgefuehrt wird, wenn die Begingung wahr ist.
|
||||
FalseEvaluator=Alternative Aktion
|
||||
FalseEvaluatorHelp=Aktion, die nur dann ausgefuehrt wird, wenn die Bedingung nicht wahr ist.
|
||||
DoEnergy=Energie aendern
|
||||
DoEnergyHelp=Erhoeht oder verringert die Energie eines Lebewesens. Faellt die Energie auf oder unter 0, stirbt das Lebewesen. Die Energie kann nicht ueber die Maximalenergie erhoeht werden.
|
||||
DoEnergyObjectHelp=Objekt, dessen Energie geaendert wird.
|
||||
ValueChange=Aenderung
|
||||
DoEnergyValueChangeHelp=Wert um dne die Energie geaendert wird.
|
||||
|
|
|
@ -282,3 +282,8 @@ TrueEvaluator=Conditioned action
|
|||
TrueEvaluatorHelp=Action that is executed if the condition is true.
|
||||
FalseEvaluator=Else action
|
||||
FalseEvaluatorHelp=Action that is executed if the condition is false.
|
||||
DoEnergy=Adjust energy
|
||||
DoEnergyHelp=Increases or decreases the energy of a living object (e.g. a clonk). If energy falls to or below 0, the object dies. Energy cannot be increased beyond the maximum energy of the object (50 for clonks).
|
||||
DoEnergyObjectHelp=Object for which energy is adjusted.
|
||||
ValueChange=Change
|
||||
DoEnergyValueChangeHelp=Value that is added to the current energy of the object.
|
||||
|
|
Loading…
Reference in New Issue