View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0003391||The Dark Mod||Coding||public||29.04.2013 01:22||29.04.2013 20:12|
|Product Version||TDM 2.00|
|Target Version||TDM 2.00||Fixed in Version||TDM 2.00|
|Summary||0003391: Allow warnings and crashes when def entities don't exist|
|Description||As we head for standalone, we need to know when entities defined in the *.def files don't exist (i.e. we rely on D3 definitions).|
The code currently works at cross-purposes in a few spots. At a high level, the code asks for an entity definition, and wants to crash or emit a console warning if it doesn't exist. However, at a lower level, where the entity definition is being retrieved, if it doesn't exist, a dummy is created and handed to the higher level. The higher level says, okay, that's great, this thing exists, so no crash or warning.
Since we want the crashes and warning to alert us to missing definitions, this issue covers code changes to stop supplying dummy default entities in the low level code.
|Tags||No tags attached.|
In many locations, calls to gameLocal.FindEntityDefDict() are followed by warnings or errors for non-existent definitions. Some of these locations were unknowingly asking this routine to provide an empty default definition, which makes no sense, because the errors and warnings would then not be processed.
To let us see where definitions are missing, I changed the calls to NOT ask for a default. This allows the error or warning code to run, either crashing TDM back to the main menu with an error message complaining about the missing definition, or writing a warning to the console.
All calls to this routine that asked for a default to be provided were left as is.
All calls to this routine that were already asking that a default not be provided were left as is.
Tested with victim.map.
Changed the spots where I’d added an explicit “false” to gameLocal.FindEntityDefDict() so that they’d ask for “true”, and added warnings to that routine and three others so that missing resources could be identified.
The warning format is “STANDALONE – can’t find ‘xxxxxxxxx’”
In addition to the source files listed above, the following files were changed:
|29.04.2013 01:22||grayman||New Issue|
|29.04.2013 01:22||grayman||Status||new => assigned|
|29.04.2013 01:22||grayman||Assigned To||=> grayman|
|29.04.2013 02:34||grayman||Note Added: 0005337|
|29.04.2013 02:34||grayman||Status||assigned => resolved|
|29.04.2013 02:34||grayman||Resolution||open => fixed|
|29.04.2013 02:34||grayman||Fixed in Version||=> TDM 2.00|
|29.04.2013 20:12||grayman||Note Added: 0005339|