- Fixed: When starting a level while the music has been paused S_Start has
to stop the old music so the new one always starts at the beginning. - Fixed:: AActor::master was not serialized. - Fixed: Sound targets pointing to dead players should be cleared before respawning the player. - Fixed: When the DONTMOVE flag is set A_Chase must not call P_NewChaseDir. - Changed PowerupGiver initialization so that the actual powerup class is looked up during postprocessing. - Gave Strife's instant death sector type its own damage type. SVN r778 (trunk)
This commit is contained in:
parent
3b991c3070
commit
03617dc6f0
8 changed files with 77 additions and 19 deletions
|
|
@ -539,6 +539,41 @@ void FinishThingdef()
|
|||
}
|
||||
}
|
||||
|
||||
if (ti->IsDescendantOf(RUNTIME_CLASS(APowerupGiver)) && ti != RUNTIME_CLASS(APowerupGiver))
|
||||
{
|
||||
FString typestr;
|
||||
APowerupGiver * defaults=(APowerupGiver *)ti->Defaults;
|
||||
fuglyname v;
|
||||
|
||||
v = defaults->PowerupType;
|
||||
if (v != NAME_None && v.IsValidName())
|
||||
{
|
||||
typestr.Format ("Power%s", v.GetChars());
|
||||
const PClass * powertype=PClass::FindClass(typestr);
|
||||
if (!powertype) powertype=PClass::FindClass(v.GetChars());
|
||||
|
||||
if (!powertype)
|
||||
{
|
||||
Printf("Unknown powerup type '%s' in '%s'\n", v.GetChars(), ti->TypeName.GetChars());
|
||||
errorcount++;
|
||||
}
|
||||
else if (!powertype->IsDescendantOf(RUNTIME_CLASS(APowerup)))
|
||||
{
|
||||
Printf("Invalid powerup type '%s' in '%s'\n", v.GetChars(), ti->TypeName.GetChars());
|
||||
errorcount++;
|
||||
}
|
||||
else
|
||||
{
|
||||
defaults->PowerupType=powertype;
|
||||
}
|
||||
}
|
||||
else if (v == NAME_None)
|
||||
{
|
||||
Printf("No powerup type specified in '%s'\n", ti->TypeName.GetChars());
|
||||
errorcount++;
|
||||
}
|
||||
}
|
||||
|
||||
// the typeinfo properties of weapons have to be fixed here after all actors have been declared
|
||||
if (ti->IsDescendantOf(RUNTIME_CLASS(AWeapon)))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue