Defender's Quest: Valley of the Forgotten

Defender's Quest: Valley of the Forgotten

View Stats:
[App Crash] "DefendersQuest.exe has stopped working" crash in Endless 1 & 2
I've had the game (HD remaster) crash twice so far. Both times it was an application crash with a windows error message stating "DefendersQuest.exe has stopped working". The crashes occured while playing on the Endless bonus challenges.

The first crash was on Endless 1. I reached wave ~73 just before crashing. The second was on Endless 2. I reached wave ~65 before crashing.

In both cases the game was becoming unresponsive prior to the crash. It was getting noticeably stuttering and the game wasn't accepting any input very well. As in, it would take numerous attempts to even try to adjust speed and near the end it simply wasn't possible to do. The higher the speed setting the worse the stuttering and more unresponsive it was. (I relieve in the first case I was on speed 4 and the second speed 6 or 8.)



It almost seems like a memory leak since the more wave you go through, and thus the longer the mission is, the worse the performance gets.

UPDATE - It definitely is just an overall performance loss over time and not a matter of speeds. I'm at wave 59 of Endless 2 currently and am at Speed 1 which is how I played the whole event so far. By this point its very choppy as if the game is skipping a few frames of animation all the time. Input is delayed or ignored regularly.

For instance, I pressed ESC three times back to back. Nothing happened initially. But then about 10 seconds later the menu screen called up. I clicked the close button with the mouse. About 30 seconds later the menu came up a second time and I closed it with the mouse. Then almost a full two minutes later the menu came up a third time and required being closed.
Last edited by BOYCOTT S-T-E-A-M!; 22 Jun, 2016 @ 3:09am
< >
Showing 1-10 of 10 comments
lars.doucet  [developer] 22 Jun, 2016 @ 4:35am 
HAve you tried the test_public beta branch yet with version 2.0.3a ? I'm getting reports that that patch drastically improves performance.
Ah I wasn't aware this game was making use of the Steam beta feature. I thought all the updates and hotfixes were just automatically being applied.

I'll nab that and give it a shot when I can here. Thanks for the information.
lars.doucet  [developer] 22 Jun, 2016 @ 4:49am 
We test on the beta branch first for about a day to catch regressions :P
Good idea to check for regressions before unleashing it to everyone and risking a massive backlash!

I re-tested this situation with the public beta.

I played Endless 2 since its a much more "hands off" level to test on. I used the same unit layout as I did the last time. I tried testing at Speed 16 from start to finish. Finish in this case, sadly, being the same app crash and "DefendersQuest.exe" has stopped working message.


The game ran noticeably better for longer. Previously after wave 60 things were largely becoming a slideshow and by ~63 it would crash. This time up to wave 50 worked great. At 60 there was a noticeable drop in performance. By 70 it seemed to have a ton of frameskipping and the input was becoming unresponsive. 71 - 73 it was basically a slideshow and inputs would be ignored or massively delayed. On wave 74 it crashed.


A very noticeable improvement, but it still seems to getting worse performance the longer a level goes on. Is it possible that its a garbage collection issue of some kind thats building up over long missions like these? As I've not noticed any significant slowdowns in non-endless missions even if the amount of enemies and partile effects flying about the screen are more than in the endless levels.


I know in a program I was working on recently I had two dumb mistakes that gradually brought it to a halt. One was that a minor particle effect had a typo in the code for its death timer so despite fading away visually it was never removed from memory so the game would track it forever. The other was with a projectile that could pierce through multiple targets where I was storing which targets it already dealt damage to in a list data structure I would create so that I could ensure it didn't damage the same target multiple times. But, I forgot to destroy the list after the projectile was destroyed so even though the projectile was gone I still had a list and new projectiles meant more and more lists.
Last edited by BOYCOTT S-T-E-A-M!; 22 Jun, 2016 @ 5:17am
lars.doucet  [developer] 22 Jun, 2016 @ 5:48am 
Yeah I'm sure there's some kind of memory leak somewhere. Each performance pass I try to sniff out the biggest bottleneck and whack that first; I found a bunch of low hanging fruit last time, I'm sure I'll find something else if I dig up my memory object profiler next.
Yeah, I read about that HxScout program you used to see what was taking up the most cpu cycles. I'll have to look into that as it sounds like it would be damned handy tool to have. Very curious about that memory profiler you're talking about as well.

I know some programming, from hobby projects, but never really knew much about external debugging and performance tools so its certainly useful to hear about them.


Unsure if it might be related to this issue, but through testing I've found that the status effects from the "Dragon Fire" (Main character spell # 6) really bogs things down. It certainly slows things down while everything has the burning effect going at once. Even after it wore off things never seemed to go back fully to the same speed again. Though its possible that its just because by the time the effects end the game overall has bogged down more than prior to casting it.


EDIT - Actually, just crashed again in a way that might have useful information. I had tried doing the first challenge of New Game+. Only units available at the time were my Berserkers and my Archers. So aside from my "Dragon Fire" spell there wasn't really a heap of fancy status effects or projectiles flying about. I made it to the last wave, 50, and it was nearing the slideshow phase. I didn't crash though, I died and failed.

However, after my defeat in that challenge I went to start the next storyline mission "The Battle of Karsk." As soon as the actual level started the game was already a slideshow and crashed out before it even started spawning the baddies.

So I'd guess whatever is causing the issue can occur even with just the minimal things available at the time, enemy variety for that mission, Berserkers,and Archers.
Last edited by BOYCOTT S-T-E-A-M!; 22 Jun, 2016 @ 6:34am
lars.doucet  [developer] 22 Jun, 2016 @ 7:04am 
Hmmm, and you can confirm you're definitely on the latest version, huh (2.0.3a)? Is it at least getting better with each patch? What are your system specs?

Anyways, I'm going to go ahead and finish deploying 2.0.3a, fix a few conventional bugs, and then hop onto the memory profiler.
So far as I'm aware I am. I switched to the test_public beta that was available and my menu screen shows "Steam DQ1 2.0.3 a" in the bottom right.

The beta version is an improvement for sure. Can't comment on the other updates since there hadn't been any updates, aside from the beta which I wasn't aware of at the time, after I reached the long missions, like Endless 1 & 2, and started having crashes. Either way the beta is a noticeable performance boost and aside from these crashes I've not encountered any other bugs, before or after opting into the beta.


As for my system specs...

Operating System: Windows 7 Professional

System Type: 64 bit operating system.

CPU: AMD FX 6200 - (3.80 GHz) Six Core Processor

RAM: 16 GB

GPU: AMD Radeon GA-990FXA-UD3

If you need to know anything beyond that just lemme know what.
Just figured I'd update this to say that I believe the memory leak issue is now solved!

Using version Steam DQ 1 2.0.4 c (also says Hardware + ANGLE in bottom left), which I believe is the most current version, I wasn't able to crash it. I tried damned hard too as well.

I re-tested this version by once again playing Endless 2 and using the same unit setup as before.

I went up to wave ~107 or higher before I quit. No crashing. I put it through its paces by doing all I could to crash it such as pausing and firing off my frenzy, push, dragon fire, and heal spell while also placing a crystal which I shot with lightening. My lightening is modfied by the chain lightening book, but even with all that, and constant firing off of the lightening, it still held strong.

Granted, the framerate by this point was boardering on slideshow due to the number of enemies and particle effects and such but thats to be expected. Only thing that I think could really "solve" that issue would be to limit how many enemies could be on screen at one time and hold off further waves until room opened up.


The actual problem though seem to be fixed. No evidence of a memory leak as there was no crashing and the slowdowns were only there from the sheer volume of enemies and objects and not due to progressively bloated memory usage. Checking at times in task manager to see how much memory was being taken up showed it holding quite stable, with increases of course as the waves progressed but none of the previous ones permanent ballooning.


Kudos on the fixes! Looking forward to seeing you / your groups next project.
lars.doucet  [developer] 27 Jun, 2016 @ 7:29pm 
Glad to hear it :)

For what it's worth, I've added a few more tweaks that might speed up performance a bit more (2.0.5b, test_public). I agree that it was a bit silly to let a level like this get so full of enemies -- something we'll be more careful with in the sequel.
Last edited by lars.doucet; 27 Jun, 2016 @ 7:30pm
< >
Showing 1-10 of 10 comments
Per page: 1530 50