mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-14 08:04:40 +00:00
Add sensible defaults for Console Module interface
This commit is contained in:
parent
569f3a1e41
commit
01cfa4a604
2 changed files with 9 additions and 10 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef _SCRIPT_MODULE_H_
|
#ifndef _SCRIPT_MODULE_H_
|
||||||
#define _SCRIPT_MODULE_H_
|
#define _SCRIPT_MODULE_H_
|
||||||
#include "runtime.h"
|
#include "runtime.h"
|
||||||
#include "console/console.h"
|
#include "console/console.h"
|
||||||
|
|
@ -23,22 +23,21 @@ namespace Con
|
||||||
virtual EvalResult exec(U32 offset, const char* fnName, Namespace* ns, U32 argc,
|
virtual EvalResult exec(U32 offset, const char* fnName, Namespace* ns, U32 argc,
|
||||||
ConsoleValue* argv, bool noCalls, StringTableEntry packageName,
|
ConsoleValue* argv, bool noCalls, StringTableEntry packageName,
|
||||||
S32 setFrame = -1) = 0;
|
S32 setFrame = -1) = 0;
|
||||||
virtual void findBreakLine(U32 ip, U32& line, U32& instruction) = 0;
|
virtual void findBreakLine(U32 ip, U32& line, U32& instruction) {}
|
||||||
virtual const char *getFileLine(U32 ip) = 0;
|
|
||||||
|
|
||||||
/// Returns the first breakable line or 0 if none was found.
|
/// Returns the first breakable line or 0 if none was found.
|
||||||
/// @param lineNumber The one based line number.
|
/// @param lineNumber The one based line number.
|
||||||
virtual U32 findFirstBreakLine(U32 lineNumber) = 0;
|
virtual U32 findFirstBreakLine(U32 lineNumber) { return 0; }
|
||||||
|
|
||||||
/// Set a OP_BREAK instruction on a line. If a break
|
/// Set a OP_BREAK instruction on a line. If a break
|
||||||
/// is not possible on that line it returns false.
|
/// is not possible on that line it returns false.
|
||||||
/// @param lineNumber The one based line number.
|
/// @param lineNumber The one based line number.
|
||||||
virtual bool setBreakpoint(U32 lineNumber) = 0;
|
virtual bool setBreakpoint(U32 lineNumber) { return false;}
|
||||||
|
|
||||||
virtual void setAllBreaks() = 0;
|
virtual void setAllBreaks() {}
|
||||||
virtual void clearAllBreaks() = 0;
|
virtual void clearAllBreaks() {}
|
||||||
virtual void clearBreakpoint(U32 lineNumber) = 0;
|
virtual void clearBreakpoint(U32 lineNumber) {}
|
||||||
virtual Vector<U32> getBreakableLines() = 0;
|
virtual Vector<U32> getBreakableLines() { return {}; }
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -115,7 +115,7 @@ public:
|
||||||
bool setBreakpoint(U32 lineNumber) override;
|
bool setBreakpoint(U32 lineNumber) override;
|
||||||
|
|
||||||
void findBreakLine(U32 ip, U32 &line, U32 &instruction) override;
|
void findBreakLine(U32 ip, U32 &line, U32 &instruction) override;
|
||||||
const char *getFileLine(U32 ip) override;
|
const char *getFileLine(U32 ip);
|
||||||
|
|
||||||
///
|
///
|
||||||
String getFunctionArgs(U32 offset);
|
String getFunctionArgs(U32 offset);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue