Added capability to toggle debug state in plugins at runtime

--HG--
extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40295
This commit is contained in:
Borja Ferrer
2007-01-15 00:56:39 +00:00
parent e13c228c5a
commit 89350a1785
6 changed files with 150 additions and 14 deletions
+9
View File
@@ -29,6 +29,15 @@ BaseContext::BaseContext(sp_context_t *_ctx)
m_CustomMsg = false;
}
void BaseContext::SetContext(sp_context_t *_ctx)
{
if (!_ctx)
{
return;
}
ctx = _ctx;
}
IVirtualMachine *BaseContext::GetVirtualMachine()
{
return (IVirtualMachine *)ctx->vmbase;
+2
View File
@@ -52,6 +52,8 @@ namespace SourcePawn
virtual int LookupFile(ucell_t addr, const char **filename);
virtual int LookupFunction(ucell_t addr, const char **name);
virtual int LookupLine(ucell_t addr, uint32_t *line);
public:
void SetContext(sp_context_t *_ctx);
private:
void SetErrorMessage(const char *msg, va_list ap);
private: