This commit is contained in:
Rachael Alexanderson 2017-02-22 22:39:34 -05:00
commit 271c75ab9b
13 changed files with 1973 additions and 1994 deletions

View file

@ -544,7 +544,6 @@ void FullGC()
void Barrier(DObject *pointing, DObject *pointed)
{
assert(pointed->GetClass() != nullptr);
assert(pointing == NULL || (pointing->IsBlack() && !pointing->IsDead()));
assert(pointed->IsWhite() && !pointed->IsDead());
assert(State != GCS_Finalize && State != GCS_Pause);

View file

@ -53,6 +53,9 @@ DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, gametype)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, norandomplayerclass)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, infoPages)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, mBackButton)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, mStatscreenMapNameFont)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, mStatscreenEnteringFont)
DEFINE_FIELD_X(GameInfoStruct, gameinfo_t, mStatscreenFinishedFont)
const char *GameNames[17] =

View file

@ -411,7 +411,7 @@ static void ParseListMenuBody(FScanner &sc, DListMenuDescriptor *desc)
else if (args[i] == TypeTextureID)
{
auto f = TexMan.CheckForTexture(sc.String, FTexture::TEX_MiscPatch);
if (!f.isValid())
if (!f.Exists())
{
sc.ScriptError("Unknown texture %s", sc.String);
}

View file

@ -2821,6 +2821,8 @@ void FBehavior::StaticStartTypedScripts (WORD type, AActor *activator, bool alwa
"Unloading",
"Disconnect",
"Return",
"Event",
"Kill",
"Reopen"
};
DPrintf(DMSG_NOTIFY, "Starting all scripts of type %d (%s)\n", type,

View file

@ -568,16 +568,6 @@ FStrifeDialogueNode::~FStrifeDialogueNode ()
}
}
//============================================================================
//
// FStrifeDialogueReply :: ~FStrifeDialogueReply
//
//============================================================================
FStrifeDialogueReply::~FStrifeDialogueReply ()
{
}
//============================================================================
//
// FindNode

View file

@ -20,19 +20,19 @@ struct FStrifeDialogueItemCheck
struct FStrifeDialogueNode
{
~FStrifeDialogueNode ();
PClassActor *DropType;
PClassActor *DropType = nullptr;
TArray<FStrifeDialogueItemCheck> ItemCheck;
int ThisNodeNum; // location of this node in StrifeDialogues
int ItemCheckNode; // index into StrifeDialogues
int ThisNodeNum = 0; // location of this node in StrifeDialogues
int ItemCheckNode = 0; // index into StrifeDialogues
PClassActor *SpeakerType;
PClassActor *SpeakerType = nullptr;
FString SpeakerName;
FSoundID SpeakerVoice;
FString Backdrop;
FString Dialogue;
FString Goodbye; // must init to null for binary scripts to work as intended
FStrifeDialogueReply *Children;
FStrifeDialogueReply *Children = nullptr;
FName MenuClassName;
FString UserData;
};
@ -40,13 +40,11 @@ struct FStrifeDialogueNode
// FStrifeDialogueReply holds responses the player can give to the NPC
struct FStrifeDialogueReply
{
~FStrifeDialogueReply ();
FStrifeDialogueReply *Next;
PClassActor *GiveType;
int ActionSpecial;
int Args[5];
int PrintAmount;
FStrifeDialogueReply *Next = nullptr;
PClassActor *GiveType = nullptr;
int ActionSpecial = 0;
int Args[5] = {};
int PrintAmount = 0;
TArray<FStrifeDialogueItemCheck> ItemCheck;
TArray<FStrifeDialogueItemCheck> ItemCheckRequire;
TArray<FStrifeDialogueItemCheck> ItemCheckExclude;
@ -54,9 +52,9 @@ struct FStrifeDialogueReply
FString QuickYes;
FString QuickNo;
FString LogString;
int NextNode; // index into StrifeDialogues
int LogNumber;
bool NeedsGold;
int NextNode = 0; // index into StrifeDialogues
int LogNumber = 0;
bool NeedsGold = false;
};
extern TArray<FStrifeDialogueNode *> StrifeDialogues;

View file

@ -121,7 +121,6 @@ class USDFParser : public UDMFParserBase
bool ParseChoice(FStrifeDialogueReply **&replyptr)
{
FStrifeDialogueReply *reply = new FStrifeDialogueReply;
memset(reply, 0, sizeof(*reply));
reply->Next = *replyptr;
*replyptr = reply;
@ -293,8 +292,6 @@ class USDFParser : public UDMFParserBase
{
FStrifeDialogueNode *node = new FStrifeDialogueNode;
FStrifeDialogueReply **replyptr = &node->Children;
memset(node, 0, sizeof(*node));
//node->ItemCheckCount[0] = node->ItemCheckCount[1] = node->ItemCheckCount[2] = -1;
node->ThisNodeNum = StrifeDialogues.Push(node);
node->ItemCheckNode = -1;

View file

@ -315,9 +315,7 @@ do_stop:
do
{
sc.MustGetString();
#ifdef DYNLIGHT
AddStateLight(&state, sc.String);
#endif
AddStateLight(&state, sc.String);
}
while (sc.CheckString(","));
sc.MustGetStringName(")");

View file

@ -2562,7 +2562,7 @@ void ZCCCompiler::CompileStates()
state.Misc1 = IntConstFromNode(sl->Offset, c->Type());
state.Misc2 = IntConstFromNode(static_cast<ZCC_Expression *>(sl->Offset->SiblingNext), c->Type());
}
#ifdef DYNLIGHT
if (sl->Lights != nullptr)
{
auto l = sl->Lights;
@ -2572,7 +2572,6 @@ void ZCCCompiler::CompileStates()
l = static_cast<decltype(l)>(l->SiblingNext);
} while (l != sl->Lights);
}
#endif
if (sl->Action != nullptr)
{

View file

@ -87,8 +87,6 @@ const char *GetVersionString();
// SVN revision ever got.
#define SAVEVER 4550
#define DYNLIGHT
// This is so that derivates can use the same savegame versions without worrying about engine compatibility
#define GAMESIG "QZDOOM"
#define BASEWAD "qzdoom.pk3"

File diff suppressed because it is too large Load diff

View file

@ -290,6 +290,12 @@ struct CVar native
native int ResetToDefault();
}
struct GIFont
{
Name fontname;
Name color;
};
struct GameInfoStruct native
{
// will be extended as needed.
@ -301,6 +307,9 @@ struct GameInfoStruct native
native bool norandomplayerclass;
native Array<Name> infoPages;
native String mBackButton;
native GIFont mStatscreenMapNameFont;
native GIFont mStatscreenEnteringFont;
native GIFont mStatscreenFinishedFont;
}
class Object native

View file

@ -2651,16 +2651,6 @@ flickerlight LGNTAIL
chance 0.8
}
object StrifeZap1
{
frame ZAP1A { light ARROWZAP1 }
frame ZAP1B { light ARROWZAP2 }
frame ZAP1C { light ARROWZAP3 }
frame ZAP1D { light ARROWZAP4 }
frame ZAP1E { light ARROWZAP5 }
frame ZAP1F { light ARROWZAP6 }
}
object SpectralLightningBase
{
frame ZAP1A { light ARROWZAP1 }
@ -2871,4 +2861,4 @@ object TeleportFog
frame TFOGD { light TFOG4 }
frame TFOGE { light TFOG5 }
frame TFOGF { light TFOG6 }
}
}