mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-06-04 19:01:18 +00:00
Warning about missing DECORATE actors was shown twice.
This commit is contained in:
parent
735447edbe
commit
7f775bbbd2
1 changed files with 5 additions and 8 deletions
|
@ -1415,6 +1415,9 @@ namespace CodeImp.DoomBuilder.Data
|
||||||
actors.Add(className, actor.DoomEdNum);
|
actors.Add(className, actor.DoomEdNum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (actors.Count == 0)
|
||||||
|
General.ErrorLogger.Add(ErrorType.Warning, "Warning: unable to find any DECORATE actors definition!");
|
||||||
|
|
||||||
return actors;
|
return actors;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1467,10 +1470,7 @@ namespace CodeImp.DoomBuilder.Data
|
||||||
//mxd. This parses modeldefs. Should be called after all DECORATE actors are parsed and actorsByClass dictionary created
|
//mxd. This parses modeldefs. Should be called after all DECORATE actors are parsed and actorsByClass dictionary created
|
||||||
private void loadModeldefs(Dictionary<string, int> actorsByClass) {
|
private void loadModeldefs(Dictionary<string, int> actorsByClass) {
|
||||||
//if no actors defined in DECORATE or game config...
|
//if no actors defined in DECORATE or game config...
|
||||||
if (actorsByClass == null || actorsByClass.Count == 0) {
|
if (actorsByClass == null || actorsByClass.Count == 0) return;
|
||||||
General.ErrorLogger.Add(ErrorType.Warning, "Warning: current game has no Actors!");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
Dictionary<string, ModelData> modelDefEntriesByName = new Dictionary<string, ModelData>();
|
Dictionary<string, ModelData> modelDefEntriesByName = new Dictionary<string, ModelData>();
|
||||||
ModeldefParser mdeParser = new ModeldefParser();
|
ModeldefParser mdeParser = new ModeldefParser();
|
||||||
|
@ -1504,10 +1504,7 @@ namespace CodeImp.DoomBuilder.Data
|
||||||
//mxd. This parses gldefs. Should be called after all DECORATE actors are parsed and actorsByClass dictionary created
|
//mxd. This parses gldefs. Should be called after all DECORATE actors are parsed and actorsByClass dictionary created
|
||||||
private void loadGldefs(Dictionary<string, int> actorsByClass) {
|
private void loadGldefs(Dictionary<string, int> actorsByClass) {
|
||||||
//if no actors defined in DECORATE or game config...
|
//if no actors defined in DECORATE or game config...
|
||||||
if (actorsByClass == null || actorsByClass.Count == 0) {
|
if (actorsByClass == null || actorsByClass.Count == 0) return;
|
||||||
General.ErrorLogger.Add(ErrorType.Warning, "Warning: unable to find any DECORATE actors definition!");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
GldefsParser parser = new GldefsParser();
|
GldefsParser parser = new GldefsParser();
|
||||||
parser.OnInclude = loadGldefsFromLocation;
|
parser.OnInclude = loadGldefsFromLocation;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue