mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-22 20:02:48 +00:00
Fixed an issue that prevented models from being loaded correctly when some model indices in MODELDEF were unused. Fixes #727
This commit is contained in:
parent
7d7e2e98b4
commit
3cda0e53d1
1 changed files with 1 additions and 1 deletions
|
@ -200,7 +200,7 @@ namespace CodeImp.DoomBuilder.ZDoom
|
|||
foreach(var fs in mds.Frames[targetsprite])
|
||||
{
|
||||
// Sanity checks
|
||||
if(fs.ModelIndex >= mds.ModelNames.Count || string.IsNullOrEmpty(mds.ModelNames[fs.ModelIndex]))
|
||||
if (!mds.ModelNames.ContainsKey(fs.ModelIndex) || string.IsNullOrEmpty(mds.ModelNames[fs.ModelIndex]))
|
||||
{
|
||||
LogWarning("Model definition \"" + classname + "\", frame \"" + fs.SpriteName + " " + fs.FrameName + "\" references undefined model index " + fs.ModelIndex);
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue