Commit graph

30 commits

Author SHA1 Message Date
Jeff Hutchinson 2e03108856 Optionally allow to treat script assert as warning
This commit allows us to treat variable use before assign errors and local variables inside of the global scope as warnings instead of asserts. This will allow for easier porting of legacy scripts. It is highly recommended use this as an aid to port scripts, but can be used in production if needbe.
2021-11-17 18:01:35 -05:00
Robert MacGregor 5d26dba7da * BugFix: Clear some MSVC compiler warnings. 2021-10-07 00:27:39 -04:00
Jeff Hutchinson 2d50f52cf1 Allow local variables to be used in eval. 2021-09-20 21:00:33 -04:00
Jeff Hutchinson 55c0a748b4 Don't generate op_inc whenever its used as an expression. 2021-09-07 19:43:39 -04:00
Jeff Hutchinson 8d75d60f91 Write out variable mapping table to DSO stream, and fix .dump() 2021-09-01 22:15:37 -04:00
Jeff Hutchinson 1b54162580 cleanup todos 2021-08-19 22:25:11 -04:00
Jeff Hutchinson 59312d7d52 debugger support 2021-08-19 22:05:43 -04:00
Jeff Hutchinson 98a2fa0f33 Fix bugs with internalName accessor 2021-08-17 20:52:59 -04:00
Jeff Hutchinson 6ec40e86da Fix bugs with certain properties (and .x .y .z accessors) and add tests. 2021-08-16 22:02:24 -04:00
Jeff Hutchinson a449fadde2 hacks to make thedebugger work again. 2021-08-14 01:37:01 -04:00
Jeff Hutchinson 464cb7ae29 Better error messages when compiling script. 2021-06-19 13:48:32 -04:00
Jeff Hutchinson 085af8e762 fix %obj.field op assign. 2021-06-19 12:28:32 -04:00
Jeff Hutchinson 964fde8f09 Goodbye String Stack! 2021-04-29 23:11:49 -04:00
Jeff Hutchinson bb12638ea5 Added error checking for using a local variable in global scope, and added optimization to method object parameter. 2021-04-17 14:31:27 -04:00
Jeff Hutchinson bfc0109485 fixes and some minor bc adjustment. 2021-04-16 23:21:39 -04:00
Jeff Hutchinson 4e678292e1 fix foreach/foreach$ loops. 2021-04-04 00:50:37 -04:00
Jeff Hutchinson 35500a87c6 initial port of the new interpreter 2021-03-30 19:33:19 -04:00
AzaezelX 2c1508c169 uninitialized variables-console 2020-05-11 14:40:31 -05:00
Azaezel e80b66464e ast shadowvar cleanup 2018-03-16 20:04:14 -05:00
Jeff Hutchinson d7287914c7 fix arg corruption on functioncall compilation. 2017-11-12 14:21:49 -05:00
Areloch d666322a1b Merging 2017-11-05 22:33:32 -06:00
Azaezel 555610f69f Addresses roughly half of the C4189 errors though the following methodologies:
1) truly unused vars removed
2) vars leading to remmed out code for debugging remmed in turn.

left out:
vars in macros.
2015-07-29 03:03:27 -05:00
Daniel Buckmaster a4f7182de5 Fix omissions in astNodes.cpp. 2014-10-28 08:55:17 +11:00
Daniel Buckmaster b507dc9555 Merge branch 'master' into console-func-refactor
Conflicts:
	Engine/source/app/net/net.cpp
	Engine/source/console/astNodes.cpp
	Engine/source/console/compiledEval.cpp
	Engine/source/console/console.h
	Engine/source/console/consoleInternal.h
	Engine/source/console/engineAPI.h
2014-10-14 15:09:11 +11:00
James Urquhart 1e44586606 Refactor TS compiler to not use the precompile step & also 64bit support
- Reduces headaches
- Expands STE entry size to allow for 64bit values
- Bonus: Adds in function lookup optimization from T2D
2014-09-07 21:43:56 +01:00
DavidWyand-GG 539efcb1e1 Input event changes
- New InputEventManager class.  It will be used by 3rd party input
devices to generate Torque 3D input events.
- Expanded the input event signal to include three new floats and a new
integer.
- Expanded the number of joystick buttons to 48.
- The input virtual map is now extendable rather than hard coded.
- The input devices types are now extendable rather than hard coded.
- New SI_POS, SI_ROT, SI_INT, and SI_FLOAT input event types.
- New SI_VALUE input action type.
- ActionMap has been updated to work with these changes.
- Removed unnecessary references to platform/event.h
2013-01-22 18:17:41 -05:00
jamesu 08d4f6ebc0 Improvements to console refactor code
- Prevent stack corruption in a few places
- Use correct type in printfs
- Reduce type conversions in EngineApi & dAto*
- Fix compilation on GCC
- Tidy up code
2012-10-12 19:12:06 +01:00
James Urquhart e99eadd61f Optimize variable-to-variable assignment 2012-10-12 18:57:28 +01:00
James Urquhart 38c8e52c1d Beginnings of the "pass everything using a native type wrapper" console code.
- ConsoleValue class is now the base value class.
- ConsoleValueRef is now used to supply function parameters. Values are disposable.
- Script functions return values instead of just strings where possible.
- Variables can be disposable strings
- Bytecode changed

Fix the issues with console method parameters and fields which prevented missions from loading.
2012-10-12 18:56:17 +01:00
DavidWyand-GG 7dbfe6994d Engine directory for ticket #1 2012-09-19 11:15:01 -04:00