1
0
Fork 0
mirror of https://github.com/suchmememanyskill/TegraExplorer.git synced 2025-02-22 16:35:56 +00:00
TegraExplorer/source/tegraexplorer/script/scriptCtx.h

19 lines
729 B
C
Raw Normal View History

2020-11-06 21:19:29 +01:00
#pragma once
#include "types.h"
#define TEXTHOLDEREMPTY() (textHolder_t) {0}
#define TEXTHOLDER(start, len) (textHolder_t) {start, len, 1}
u8 setIndentInstruction(scriptCtx_t* ctx, u8 level, u8 skip, int jumpLoc);
void destroyScriptCtx(scriptCtx_t* ctx);
scriptCtx_t createScriptCtx();
static inline indentInstructor_t getCurIndentInstruction(scriptCtx_t* ctx);
static inline u8 setCurIndentInstruction(scriptCtx_t* ctx, u8 skip, int jumpLoc);
static inline u8 setCurIndentInstruction(scriptCtx_t* ctx, u8 skip, int jumpLoc) {
return setIndentInstruction(ctx, ctx->indentLevel, skip, jumpLoc);
}
static inline indentInstructor_t getCurIndentInstruction(scriptCtx_t* ctx) {
return ctx->indentInstructors[ctx->indentLevel];
}