Package mindustry.logic
Class LStatement
java.lang.Object
mindustry.logic.LStatement
- Direct Known Subclasses:
LStatements.ApplyStatusStatement
,LStatements.ClientDataStatement
,LStatements.CommentStatement
,LStatements.ControlStatement
,LStatements.CutsceneStatement
,LStatements.DrawFlushStatement
,LStatements.DrawStatement
,LStatements.EffectStatement
,LStatements.EndStatement
,LStatements.ExplosionStatement
,LStatements.FetchStatement
,LStatements.FlushMessageStatement
,LStatements.FormatStatement
,LStatements.GetBlockStatement
,LStatements.GetFlagStatement
,LStatements.GetLinkStatement
,LStatements.InvalidStatement
,LStatements.JumpStatement
,LStatements.LocalePrintStatement
,LStatements.LookupStatement
,LStatements.MakeMarkerStatement
,LStatements.OperationStatement
,LStatements.PackColorStatement
,LStatements.PlaySoundStatement
,LStatements.PrintCharStatement
,LStatements.PrintFlushStatement
,LStatements.PrintStatement
,LStatements.RadarStatement
,LStatements.ReadStatement
,LStatements.SensorStatement
,LStatements.SetBlockStatement
,LStatements.SetFlagStatement
,LStatements.SetMarkerStatement
,LStatements.SetPropStatement
,LStatements.SetRateStatement
,LStatements.SetRuleStatement
,LStatements.SetStatement
,LStatements.SpawnUnitStatement
,LStatements.SpawnWaveStatement
,LStatements.StopStatement
,LStatements.SyncStatement
,LStatements.UnitBindStatement
,LStatements.UnitControlStatement
,LStatements.UnitLocateStatement
,LStatements.WaitStatement
,LStatements.WeatherSenseStatement
,LStatements.WeatherSetStatement
,LStatements.WriteStatement
A statement is an intermediate representation of an instruction, to be used mostly in UI.
Contains all relevant variable information.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
abstract void
build
(arc.scene.ui.layout.Table table) abstract LExecutor.LInstruction
build
(LAssembler builder) category()
protected arc.scene.ui.layout.Cell<arc.scene.ui.Button>
Adds color edit buttoncopy()
protected arc.scene.ui.layout.Cell<arc.scene.ui.TextField>
protected arc.scene.ui.layout.Cell<arc.scene.ui.TextField>
protected arc.scene.ui.layout.Cell<arc.scene.ui.TextField>
protected arc.scene.ui.layout.Cell<arc.scene.ui.TextField>
Puts the text and field in one table, taking up one cell.boolean
hidden()
name()
boolean
If true, this statement is considered useless with privileged processors and is not allowed in them.protected void
param
(arc.scene.ui.layout.Cell<arc.scene.ui.Label> label) boolean
Privileged instructions are only allowed in world processors.protected void
row
(arc.scene.ui.layout.Table table) protected String
void
saveUI()
void
setupUI()
protected <T> void
showSelect
(arc.scene.ui.Button b, T[] values, T current, arc.func.Cons<T> getter) protected <T> void
showSelect
(arc.scene.ui.Button b, T[] values, T current, arc.func.Cons<T> getter, int cols, arc.func.Cons<arc.scene.ui.layout.Cell> sizer) protected void
showSelectTable
(arc.scene.ui.Button b, arc.func.Cons2<arc.scene.ui.layout.Table, Runnable> hideCons) void
write
(StringBuilder builder)
-
Field Details
-
elem
-
-
Constructor Details
-
LStatement
public LStatement()
-
-
Method Details
-
build
public abstract void build(arc.scene.ui.layout.Table table) -
build
-
category
-
copy
-
privileged
public boolean privileged()Privileged instructions are only allowed in world processors. -
nonPrivileged
public boolean nonPrivileged()If true, this statement is considered useless with privileged processors and is not allowed in them. -
param
protected void param(arc.scene.ui.layout.Cell<arc.scene.ui.Label> label) -
sanitize
-
field
-
fields
-
fieldst
protected arc.scene.ui.layout.Cell<arc.scene.ui.TextField> fieldst(arc.scene.ui.layout.Table table, String desc, String value, arc.func.Cons<String> setter) Puts the text and field in one table, taking up one cell. -
col
protected arc.scene.ui.layout.Cell<arc.scene.ui.Button> col(arc.scene.ui.layout.Table table, String value, arc.func.Cons<arc.graphics.Color> setter) Adds color edit button -
fields
-
row
protected void row(arc.scene.ui.layout.Table table) -
showSelect
protected <T> void showSelect(arc.scene.ui.Button b, T[] values, T current, arc.func.Cons<T> getter, int cols, arc.func.Cons<arc.scene.ui.layout.Cell> sizer) -
showSelect
protected <T> void showSelect(arc.scene.ui.Button b, T[] values, T current, arc.func.Cons<T> getter) -
showSelectTable
protected void showSelectTable(arc.scene.ui.Button b, arc.func.Cons2<arc.scene.ui.layout.Table, Runnable> hideCons) -
afterRead
public void afterRead() -
write
-
setupUI
public void setupUI() -
saveUI
public void saveUI() -
name
-