Fixed mobs that don't naturally spawn.
This commit is contained in:
parent
acff6148b6
commit
80b97fd9dd
@ -761,9 +761,10 @@ cMonster::eFamily cMonster::FamilyFromType(eType a_Type)
|
|||||||
case mtChicken: return mfPassive;
|
case mtChicken: return mfPassive;
|
||||||
case mtCow: return mfPassive;
|
case mtCow: return mfPassive;
|
||||||
case mtCreeper: return mfHostile;
|
case mtCreeper: return mfHostile;
|
||||||
|
case mtEnderDragon: return mfNoSpawn;
|
||||||
case mtEnderman: return mfHostile;
|
case mtEnderman: return mfHostile;
|
||||||
case mtGhast: return mfHostile;
|
case mtGhast: return mfHostile;
|
||||||
case mtGiant: return mfHostile;
|
case mtGiant: return mfNoSpawn;
|
||||||
case mtHorse: return mfPassive;
|
case mtHorse: return mfPassive;
|
||||||
case mtIronGolem: return mfPassive;
|
case mtIronGolem: return mfPassive;
|
||||||
case mtMagmaCube: return mfHostile;
|
case mtMagmaCube: return mfHostile;
|
||||||
@ -774,11 +775,12 @@ cMonster::eFamily cMonster::FamilyFromType(eType a_Type)
|
|||||||
case mtSilverfish: return mfHostile;
|
case mtSilverfish: return mfHostile;
|
||||||
case mtSkeleton: return mfHostile;
|
case mtSkeleton: return mfHostile;
|
||||||
case mtSlime: return mfHostile;
|
case mtSlime: return mfHostile;
|
||||||
|
case mtSnowGolem: return mfNoSpawn;
|
||||||
case mtSpider: return mfHostile;
|
case mtSpider: return mfHostile;
|
||||||
case mtSquid: return mfWater;
|
case mtSquid: return mfWater;
|
||||||
case mtVillager: return mfPassive;
|
case mtVillager: return mfPassive;
|
||||||
case mtWitch: return mfHostile;
|
case mtWitch: return mfHostile;
|
||||||
case mtWither: return mfHostile;
|
case mtWither: return mfNoSpawn;
|
||||||
case mtWolf: return mfHostile;
|
case mtWolf: return mfHostile;
|
||||||
case mtZombie: return mfHostile;
|
case mtZombie: return mfHostile;
|
||||||
case mtZombiePigman: return mfHostile;
|
case mtZombiePigman: return mfHostile;
|
||||||
@ -801,6 +803,7 @@ int cMonster::GetSpawnDelay(cMonster::eFamily a_MobFamily)
|
|||||||
case mfPassive: return 40;
|
case mfPassive: return 40;
|
||||||
case mfAmbient: return 40;
|
case mfAmbient: return 40;
|
||||||
case mfWater: return 400;
|
case mfWater: return 400;
|
||||||
|
case mfNoSpawn: return -1;
|
||||||
case mfUnhandled: break;
|
case mfUnhandled: break;
|
||||||
}
|
}
|
||||||
ASSERT(!"Unhandled mob family");
|
ASSERT(!"Unhandled mob family");
|
||||||
|
@ -66,6 +66,7 @@ public:
|
|||||||
mfAmbient = 2, // Bats
|
mfAmbient = 2, // Bats
|
||||||
mfWater = 3, // Squid
|
mfWater = 3, // Squid
|
||||||
|
|
||||||
|
mfNoSpawn,
|
||||||
mfUnhandled, // Nothing. Be sure this is the last and the others are in order
|
mfUnhandled, // Nothing. Be sure this is the last and the others are in order
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
|
@ -67,12 +67,12 @@ bool cFile::Open(const AString & iFileName, eMode iMode)
|
|||||||
case fmRead: Mode = "rb"; break;
|
case fmRead: Mode = "rb"; break;
|
||||||
case fmWrite: Mode = "wb"; break;
|
case fmWrite: Mode = "wb"; break;
|
||||||
case fmReadWrite: Mode = "rb+"; break;
|
case fmReadWrite: Mode = "rb+"; break;
|
||||||
default:
|
}
|
||||||
|
if (Mode == NULL)
|
||||||
{
|
{
|
||||||
ASSERT(!"Unhandled file mode");
|
ASSERT(!"Unhandled file mode");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
fopen_s(&m_File, (FILE_IO_PREFIX + iFileName).c_str(), Mode);
|
fopen_s(&m_File, (FILE_IO_PREFIX + iFileName).c_str(), Mode);
|
||||||
|
Loading…
Reference in New Issue
Block a user