Commit Graph

26 Commits

Author SHA1 Message Date
Forest 96501df3d7 Use legal printf format strings when logging. 2014-09-08 02:23:45 -07:00
Kyzentun 8657d70fe1 Created Def.LogDisplay for displaying messages in a log. Changed error reporting layer to use Def.LogDisplay. Changed engine error reporting to not clip errors to a single line. 2014-08-02 00:38:29 -07:00
Kyzentun 5df80b6e0e Changed many places that used RageException to use ReportScriptError instead. Wrote ScreenOptionsExample.ini as documentation example for the OptionRow system. Rewrote gamecommands.txt to include all GameCommands. Fixed Commands::GetOriginalCommandString to insert the semicolons that separated the original commands. Changed nonsensical boolean |= true statements in GameCommand.cpp to just use =. Added protection to ReportScriptError to keep it from recursing through itself when an error occurs in error reporting. Added UseAbort option to ReportScriptError for places that want to use an AbortRetryIgnore dialog to query the user. Added ScriptErrorMessage for places that need to handle the warning/dialog part separately. Added logging flag to MESSAGEMAN so that all messages broadcast can be logged when desired. Changed OptionRowHandler::LoadInternal to return a boolean success value as part of error handling. 2014-08-02 00:38:24 -07:00
Kyzentun cc548a8cb5 Moved error reporting to ScreenSystemLayer error.lua. ScreenSystemLayer overlay/default.lua restored to previous. Error messages are now broadcast with the ScriptError message instead of SystemMessage. Added show/hide error messages toggle and clear error messages to debug menu. Nuked ScreenConsoleOverlay for being unfinished and duplicating ScreenSystemLayer. Changed Actor:tween and Tween::CreateFromStack to use ReportScriptError on invalid tween params. Changed some OptionRowList things to use ReportScriptError on invalid metrics. 2014-08-02 00:38:21 -07:00
Kyzentun a74a49af78 Changed many uses of Dialog::OK and LOG->Warn to use ReportScriptError. 2014-08-02 00:38:18 -07:00
Kyzentun 95fe1a17e9 Replaced every use of lua_call with RunScriptOnStack. Modified RunScriptOnStack to report an error to log and system message using a passed in context string. Modified every use of RunScriptOnStack to avoid crashing so that the reported error can be seen. 2014-08-02 00:38:17 -07:00
Devin J. Pohly a9d5931533 Command/LuaManager: add legacy command parsing
Only enabled when compiling via CompileXNodeTree.
2014-02-20 10:59:49 -05:00
Devin J. Pohly feb919f0bf Revert memory leak commits
5f7001e: "Added a new branch"
01456ed: "Fixed a lot of memory leaks"
dac4493: "Fixed all remaining memory leaks that I could figure out"
0792db7: "Removed the smnew macro and the call to _CrtSetDbgFlag()"

Some of these caused destructor-time problems due to static initialization
order fiasco and related issues.  Notably, the program would no longer exit on
OSX and had to be killed.

There were probably legitimate fixes in here, but since these are monolithic
commits it's too much work to extract them now.  Let's reapply them
individually and in the forward direction.
2013-04-27 00:05:14 -04:00
Shenjoku 0792db752a Removed the smnew macro and the call to _CrtSetDbgFlag() to get ready for
merging with the main branch.
2013-04-19 20:34:11 -07:00
Shenjoku 01456ed0b9 Fixed a lot of memory leaks caused by static globals never getting
deleted and some other objects not getting deleted properly due to missing
destructors.
2013-04-18 21:17:57 -07:00
Shenjoku 5f7001ef0a Added a new branch that implements support for outputting all memory leaks to
the debug output for the Debug and FastDebug project configurations. This
requires replacing all instances of new with a macro, smnew, that defines a
special form of new which outputs file and line number information along with
the memory leak details. This makes finding memory leaks much easier since you
can just double-click the leak in the output window and it will take you to the
line that caused it.
2013-04-17 20:42:29 -07:00
Jason Felds a15cbc431d War on -Werror, part 14: More hodgepodge. 2012-12-27 12:45:04 -05:00
AJ Kelly 1aee8afe87 kill GetOSName lua binding since GetArchName is better 2011-12-27 11:21:31 -06:00
AJ Kelly 046b30484b [LuaManager] Added ProductFamily() Lua binding. 2011-12-22 12:19:50 -06:00
AJ Kelly 3548810ad5 make the 'attempt to index a function value' stand out as a lua panid 2011-09-25 11:17:19 -05:00
Jason Felds da51e26d07 Standardize conversion processes.
Too many arguments for or against the many methods:
stick to one inside a common function.

This commit will force recompilation of many files.
2011-05-11 15:58:31 -04:00
Jason Felds f6acec176e [warps] Warnings are getting in my way... 2011-03-24 19:44:47 -04:00
AJ Kelly cf81f8cc3b remove xbox support; it doesn't work, and it'd take too much effort to get it working again 2011-03-19 19:28:57 -05:00
Jason Felds a085d0d1da Line endings...be normalized! 2011-03-17 01:47:30 -04:00
Jason Felds 1a1ff7d701 Give @briefs to all namespaces.
This will force recompilation of all files.
2011-02-19 12:09:03 -05:00
AJ Kelly 3bc6c16227 allow packages from Lua 2010-07-31 13:54:46 -05:00
AJ Kelly f429711dd5 Add GetOSName() binding. Returns a string representing the current OS (untested on everything but Windows, should work for everything but BSD, for which I forget the switch off the top of my head) 2010-05-13 12:01:44 -05:00
AJ Kelly dca9182138 various cleanup and commenting 2010-03-14 19:46:05 -05:00
AJ Kelly 5c5ef54a48 various changes from sm4 and sm-ssc (svn); see updated changelog for the full information 2010-02-18 23:17:24 -06:00
AJ Kelly 3e51544930 Initial commit. 2010-01-26 21:00:30 -06:00
Devin J. Pohly 80057f53cd smsvn -> ssc-hg glue: rearrange directory structure 2013-06-10 15:38:43 -04:00