mirror of
https://github.com/Anuken/Mindustry.git
synced 2026-10-02 03:00:29 +03:00
Fix processor text/graphics buffer holding old content on restart (#12663)
This commit is contained in:
@@ -122,6 +122,8 @@ public class LExecutor{
|
||||
/** Loads with a specified assembler. Resets all variables. */
|
||||
public void load(LAssembler builder){
|
||||
stop = false;
|
||||
textBuffer.setLength(0);
|
||||
graphicsBuffer.clear();
|
||||
nameMap = null;
|
||||
//retain constants that are links, which, by convention, don't start with @ (builtin) or _ (numeric constant)
|
||||
vars = builder.vars.values().toSeq().retainAll(var -> !var.constant || var.name.charAt(0) != '_' && var.name.charAt(0) != '@').toArray(LVar.class);
|
||||
|
||||
Reference in New Issue
Block a user