Commit graph

497 commits

Author SHA1 Message Date
AzaezelX a8e74787b7 new method, getMethodSigs. spits out callback proto-functions 2023-02-15 17:38:45 -06:00
AzaezelX 0d35016795 fix needing to doubleclick to bring up a docs link 2023-01-28 16:15:59 -06:00
AzaezelX 1b33b01eb1 add "docsURL" filter to assignFieldsFrom to prevent it from triggering opening web pages when inheriting values 2023-01-28 16:12:05 -06:00
AzaezelX f5a34308f9 add a docsURL; macro to link a given set of script config vars to git or similar storage urls via clicking on the inspector 2023-01-27 01:13:15 -06:00
Jeff Hutchinson 1940becb2d Compilation fixes for C++20 2022-11-28 21:39:06 -05:00
Robert MacGregor 2b8f9e3999 Merge https://github.com/TorqueGameEngines/Torque3D into feature-vfs-security 2022-06-15 18:12:39 -04:00
AzaezelX a808990bc6 you want the higher number, not the lower 2022-06-15 16:46:54 -05:00
AzaezelX c91002d5ec fix out of bounds reference in arrayobject 2022-06-13 21:10:28 -05:00
Robert MacGregor bd3a990140 * BugFix: Correct the 'gotoWebPage' function not using the VFS. 2022-06-13 12:21:06 -04:00
Robert MacGregor 1cd2b3ead9 * BugFix: Correct a small typo in the script function 'compareFileTimes'. 2022-06-13 11:45:05 -04:00
Robert MacGregor a390e0d8d5 * BugFix: Correct script function 'compareFileTimes' not going through the VFS when making the comparisons. 2022-06-13 11:43:43 -04:00
Robert MacGregor 161ffc62fe Merge branch 'Preview4_0' into feature-vfs-security 2022-06-13 08:05:26 -04:00
Jeff Hutchinson 8f2beb3219 Fix edgecase where empty string was not being explicitly set to 0 in torquescript when used as integers/floats/bools.
We found this in the setInventory standard module. in setInventory, %max was being set to empty string, but being compared to 0 during TorqueScript comparison ops. I knew to look in ConsoleValue's type conversion functions, as the interpreter internally uses ConsoleValues when working with torquescript variables under the hood. ConsoleValue is responsible for handling all type conversions on the fly as needed inside of the core interpreter logic.
2022-05-23 20:25:32 -04:00
Jeff Hutchinson 3988e7baee Better allocator for TorqueScript temp conversions used during interpretation
instead of using a Vector<> that never frees and grows for torquescript temporaries created when doing type conversions)
2022-05-21 21:55:44 -04:00
Jeff Hutchinson 59125c85eb Fix weird ternary operator in torquescript regression
With a test!
2022-04-27 21:02:55 -04:00
JeffR 5c8d8fab00 Changes behavior with suffix appending of asset importer so it doesn't contaminate the original "clean" name, which is used for setting the mapTo value of material definitions
Also adds a sanity check when applying the type suffix to see if it's already there to avoid needless doubleups
Fixes offsetting/positioning behavior on icon buttons to actually respect the icon position variable
Adds sanity checks to ensure we're not trying to utilize a in-process-of-deleting decoy dummy
Fixes handling of sliders in option menus to properly store and test unapplied values
Fixes handling of display device setting to properly store and test unapplied values
Adds additional logic to creation of shape and material asset previews to attempt to force-load dependencies to improve likelihood that they'll actually be loaded when we go to generate the preview.
Temp disables creating cubemap 'assets' via the RMB context menu in the AB
2022-04-10 01:40:15 -05:00
JeffR bfe3d4d02b Shifts handling of forest brush and item elements into standard simsets for consistency
Updates the forest editor tooling to utilize the new sets, and adjusts the creation of new Brushes in the forest editor to have user select a target module first.
This ensures all a module's brushes are grouped into the new ForestBrushGroup class which auto-registers into the ForestBrushSet, thus allowing modules to have their own sets of brushes that automatically hook into the editor workflow.
2022-04-07 18:19:13 -05:00
AzaezelX d883575d0f fix compilation flaws 2022-03-17 17:38:41 -05:00
Brian Roberts 3411dab754
Merge pull request #742 from Areloch/invisibleFileFix
Tweaks handling of "invisible" files
2022-03-16 03:30:45 -05:00
JeffR b36776d567 Tweaks handling of "invisible" files, files which start with a ., effectively making them have no filename and only an extension.
This allows the engine to actually process and work with such files.
2022-03-15 21:17:37 -05:00
JeffR 1496ffac6e Adds a systemCommand console utility function, which invokes the standard system() function call, and also has an optional callback return parameter. 2022-03-15 21:10:55 -05:00
JeffR a0f8b29da7 Improves logical checks for the default value so it's more sane and stable
Allows creation of polyhedrons via constructor with a origin and vector format, allowing to have default polyhedron values on triggers and physical zones
2022-02-14 01:07:39 -06:00
JeffR 696c2e2eec Add sanity check for default value results checking when filtering out default values
Add additional utility functions for updating parsed object data in the project importer
Adds logic to find and associate FX materials to their terrainMaterials and adding them to the terrian material asset if found on project importer
2022-02-02 01:11:33 -06:00
JeffR b4e346aa3f Adjustments to save out code when writing fields such that if the TAML writer is marked as not writing defaults, it doesn't. And makes the regular simobject save out not write default values as the default behavior 2022-01-31 20:57:57 -06:00
JeffR 630285def6 Shifts handling of material and terrain material definitions to be written into the asset definition taml file instead of having an extra loose file
Also updates importers to correctly handle this change
Adds ability for taml XML serialization to properly assign array'd fields
Adds 'inheritFrom' field to simobjects for when objects with parent objects are serialized
AssetBase how inherits from SimGroup so it can have objects like material definitions embedded in them for save/load in the taml definition file
Updated loading/handling logic in terrain material asset to be more similar to regular material assets
2022-01-30 11:50:16 -06:00
JeffR ed13bdfdd2 Changes the -> syntax check from exclusively checking simgroups to checking simsets, allowing both to be used 2022-01-21 16:01:44 -06:00
Robert MacGregor 9cf6c42fa1 * Adjustment: Tweak more manual memory management to use dStrcpy and use the VFS for directory queries always now. 2021-12-21 14:52:31 -05:00
Robert MacGregor 0e93373824 * BugFix: When querying against root with Torque::FS::DumpDirectories, correctly return directories with their path.
* Adjustment: Add commenting to some of the new programming.
* Adjustment: Tweak fileCreatedTime and fileModifiedTime functions to use the VFS.
2021-12-20 19:26:32 -05:00
Robert MacGregor 66f9336995 * Adjustment: Tweak the asset importer to use the Torque VFS functions. 2021-12-19 00:28:15 -05:00
Robert MacGregor cbe7ee13d6 * Adjustment: Change several filesystem functions to use the VFS.
* Feature: Initial implementation of a VFS dump directories function.
2021-12-18 23:37:49 -05:00
Robert MacGregor 948bc43d85 * Feature: Augment VFS file information with creation times & update some console functions to use VFS. 2021-12-18 03:56:11 -05:00
Jeff Hutchinson 73b023a4b7 Fix console warning when calling void functions in console
Forgot to add this check when rewriting the interpreter.
2021-12-08 21:00:50 -05:00
Robert MacGregor 5fa7c62ba9 * BugFix: Don't use the register keyword in the console grammar files. 2021-12-03 20:33:02 -05:00
Jeff Hutchinson 7ac62f42a3 Fixed a leak with console stack in the interpreter.
Issue was pushing a new frame in the global scope. Everytime a global scope was called, 1 ConsoleValue got allocated that was never freed. After 4096 'global scope' function calls, the engine would blow. Also cleans up an extra rogue usage of push/pop with the saver helper.
2021-11-20 19:08:02 -05:00
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
Jeff Hutchinson 949813956d Add Object Inheritence Acceptance Test 2021-11-11 22:57:09 -05:00
Brian Roberts e4428cf75a
Merge pull request #657 from Areloch/SeparateImporterLogFile
Updates asset importer and project importer to output to separate log files into tools/logs
2021-11-03 21:15:51 -05:00
JeffR fda722e355 Updates asset importer and project importer to output to separate log files into tools/logs
Add utility console function for getting current datetime
2021-11-03 00:13:00 -05:00
Robert MacGregor 2b53c065ce * BugFix: Correct an invalid memory access error caused by the tab autocomplete in the console when attempting to tab complete at the start of the input while there is text to the right. 2021-11-02 13:55:57 -04:00
Areloch 0fab2ebf54 Added fallback handling to MaterialAssets if the asset was found but the matDef was not
Added import config handling for prepending Directory to asset name
Added handling for import config of appending a sound suffix
Integrated handling of directory prepend and asset type suffix to rename issue resolution of asset importing
Corrected miswording of warn message for duplicate object names
Correct GUI issues with verve tools
Convert verve tools to utilize assets for their GUI elements
Fix window binding/naming issue depending on window mode for verve
Fix popup menus formatting for verve
WIP fix for material swap in Material editor. Corrects crash, but swap action is unreliable depending on object type
Fix display issue with mission area editor toolbar button image
Fix tooltip display of SFXEmitters in editor tree to correctly show the bound asset
Changed network graph accelerator keybind from just N to Ctrl N to avoid keybind issues when typing
Fixed Create New Emitter button in particle emitter that was showing as no texture
2021-10-28 23:52:58 -05:00
Jeff Hutchinson 4af4d90f4a Get rid of setLocalVariable entirely. 2021-10-19 20:38:13 -04:00
Jeff Hutchinson 4293aef858 This one slipped through - nextToken can't use local variable for its token variable. This was stated as one of the breaking changes in the origional PR. 2021-10-19 20:34:57 -04:00
Robert MacGregor aba091a97a Merge remote-tracking branch 'main/Preview4_0' into bugfix-msvc-compiler-warnings 2021-10-11 19:36:52 -04:00
Jeff Hutchinson 0429b5afa5 Added more tests for torquescript 2021-10-09 18:47:12 -04:00
Robert MacGregor 5d26dba7da * BugFix: Clear some MSVC compiler warnings. 2021-10-07 00:27:39 -04:00
Robert MacGregor 1b6b803a20 * BugFix: Clear a lot of warnings and correct a few actual programming errors along the way. 2021-10-04 20:04:21 -04:00
Jeff Hutchinson 755bbacaa0 Fix specific usage of Con::executef where it was not being assigned to a ConsoleValue before getting it's data out of it. 2021-09-24 19:32:57 -04:00
Jeff Hutchinson 2d50f52cf1 Allow local variables to be used in eval. 2021-09-20 21:00:33 -04:00
Robert MacGregor f9b78597f7 * BugFix: Correct an error that causes the engine to crash when calling non-namespaced engine functions incorrectly. 2021-09-16 21:21:04 -04:00
Jeff Hutchinson a7db690b59 Reimplement object copy failures. 2021-09-13 19:46:21 -04:00