1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-09-18 18:27:18 +02:00

Initial implementation of the new event system.

Initial implementation of the new signals and slots class.
Fixed command parsing which compared a pointer to a character.
Buffer overflow fix in routines which used the limits from the entity tasks.
Switched from Sqrat::Object to Sqrat::LightObj in most places to avoid the overhead of the VM pointer.
Various other adjustments and improvements.
The plugin is currently in a broken state and crashes at shutdown. The bug is unknown at this point.
This commit is contained in:
Sandu Liviu Catalin
2017-02-21 21:24:59 +02:00
parent 178b30bb20
commit 41e04e5167
39 changed files with 4859 additions and 3992 deletions

View File

@@ -212,7 +212,7 @@ Int32 Controller::Run(const Guard & guard, CCStr command)
++split;
}
// Are there any arguments specified?
if (split != '\0')
if (*split != '\0')
{
// Save the command name
ctx.mCommand.assign(command, (split - command));
@@ -665,13 +665,13 @@ bool Controller::Parse(Context & ctx)
{
// Let's us know if the whole argument was part of the resulted value
CStr next = nullptr;
// Attempt to extract the integer value from the string
// Attempt to extract the float value from the string
#ifdef SQUSEDOUBLE
const Float64 value = std::strtod(str, &next);
#else
const Float32 value = std::strtof(str, &next);
#endif // SQUSEDOUBLE
// See if this whole string was indeed an integer
// See if this whole string was indeed an float
if (next == end)
{
// Remember the current stack size