mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 00:24:40 +00:00
* BugFix: Fix a missing <vector> include for GCC.
* BugFix: Correct some globally used local variables in the editor code.
This commit is contained in:
parent
07877f246a
commit
5cce344bb1
2 changed files with 6 additions and 3 deletions
|
|
@ -23,6 +23,7 @@
|
||||||
#ifndef _CODEBLOCK_H_
|
#ifndef _CODEBLOCK_H_
|
||||||
#define _CODEBLOCK_H_
|
#define _CODEBLOCK_H_
|
||||||
|
|
||||||
|
#include <vector>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
struct CompilerLocalVariableToRegisterMappingTable
|
struct CompilerLocalVariableToRegisterMappingTable
|
||||||
|
|
|
||||||
|
|
@ -318,7 +318,8 @@ void GuiInspectorField::setData( const char* data, bool callbacks )
|
||||||
{
|
{
|
||||||
char buffer[ 2048 ];
|
char buffer[ 2048 ];
|
||||||
expandEscape( buffer, newValue );
|
expandEscape( buffer, newValue );
|
||||||
newValue = (const char*)Con::evaluatef( "%%f = \"%s\"; return ( %s );", oldValue.c_str(), buffer );
|
newValue = (const char*)Con::evaluatef( "$f = \"%s\"; return ( %s );", oldValue.c_str(), buffer );
|
||||||
|
Con::evaluatef("$f=0;");
|
||||||
}
|
}
|
||||||
else if( type == TypeS32Vector
|
else if( type == TypeS32Vector
|
||||||
|| type == TypeF32Vector
|
|| type == TypeF32Vector
|
||||||
|
|
@ -353,9 +354,10 @@ void GuiInspectorField::setData( const char* data, bool callbacks )
|
||||||
char buffer[ 2048 ];
|
char buffer[ 2048 ];
|
||||||
expandEscape( buffer, newComponentExpr );
|
expandEscape( buffer, newComponentExpr );
|
||||||
|
|
||||||
const char* newComponentVal = Con::evaluatef( "%%f = \"%s\"; %%v = \"%s\"; return ( %s );",
|
const char* newComponentVal = Con::evaluatef( "$f = \"%s\"; $v = \"%s\"; return ( %s );",
|
||||||
oldComponentVal, oldValue.c_str(), buffer );
|
oldComponentVal, oldValue.c_str(), buffer );
|
||||||
|
Con::evaluatef("$f=0;$v=0;");
|
||||||
|
|
||||||
if( !isFirst )
|
if( !isFirst )
|
||||||
strNew.append( ' ' );
|
strNew.append( ' ' );
|
||||||
strNew.append( newComponentVal );
|
strNew.append( newComponentVal );
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue