On Week 33

edited 2011 Aug 22 in Developers
skyjake:

Last week I took a short break from pure debugging to work on some important refactorings in the engine's network messaging. For years the network messages have been created rather insecurely, as I discovered when investigating why the Heretic server stopped working after starting E5M5. It turned out that the network message write buffer was overflowing and consequently overwrote some of the engine's state variables, causing the server to start thinking it was a client -- thus stopping all communications with the real clients. It become apparent that some in-depth changes were in order to fix this fundamental issue.

So, following some of the design from the Hawthorn (the old "Doomsday 2.0") branch, I created an API using which both the engine and the plugins can securely and robustly write and read network messages. It took several days to adapt all the existing code to use the new APIs, but it was worth it: now we can be sure there are no buffer overflows, unterminated strings, or incorrectly interpreted values (optional type checking).

After this work was complete, I continued on the known issues. There were a couple of important changes: 1) player mobj momentum impulses, and 2) floor hits are again enabled. 1) means that you won't get so easily stuck inside monsters any more, and 2) means water/lava splashes are spawned.

The plan is to continue working on the known issues, starting with an investigation into the occasional aberrant plane behavior, e.g., sometimes a lift stops before it reaches its destination.

danij:

Currently Doomsday will crash during startup if one attempts to play any mod which uses the in-wad highres replacement features implemented by other ports like PrBoom. A typical example is Hell Ground by Eternal. The cause is name collision, leading to miss selection. Due to there being no concept of the namespace separation model of the lump directory in other ports.

This week I started on a series of refactorings in the ringzero branch that will allow me to address the above and cross off a few items from the todo list in the process.

Rather than coalesce and flag lumps working within a fixed lump directory I decided to abstract the concept out. I generalised the implementation so it could be used with Zip files too. Note that I replaced zipindex_t with lumpnum_t (parallel ranges at resource level). My plan being an adaptive implementation of LumpDirectory that can be configured dynamically according to some externally supplied definition.

I also made some progress on whittling down the minor warning fixes including the redefining of boolean and refactoring the API to print a ruler to the console.

In addition StringPool was promoted to the public API as it would be useful to plugins.

Over the coming week I intend to continue with the LumpDirectory implementation and wire up the namespace modelling to our ResourceNamespace implementation.

Comments

  • Just a note. I was playing the TNT Evolution map 'Stronghold' and later in the map, I notice slowdowns. At first, it was just some studdering and sometimes getting increasingly choppy, then I got further (fairly close to the end) and it got so bad that the frame was almost stuck (like half a frame a second or less) things sounded like they were going in slow motion (like the chaingun guy's chaingun), and I got killed. I got back to the section of the map where only some slowdown started to occur and I traced it to particles and the only way to prevent the slowdown was to shut off the particles in the console. That shuts off blood and everything. What's up with this problem on this map? There are a vast number of chaingun guys, shotgun guys, and pistol guys in this level. I pretty sure that the number of objects isn't the problem because turning off models and textures didn't speed up the game and it shouldn't be going slower even with many models as long as there is a wall between them and my view and they aren't all drawn simultaneously. Only shutting off particles completely ceased the hanging. Shutting off dynamic lights didn't do anything.

    I hope this problem will be rectified in the coming release. I never seen another map that got hanged this badly before. Any worse and it probably would have frozen or crashed. Seems Doomsday sometimes has problems with particles. Like it did in Refueling Base in Doom II where the particles stopped appearing at certain times in the map, but that time it was a different particle problem with no slowdown.
  • gary wrote:
    Just a note. I was playing the TNT Evolution map 'Stronghold' and later in the map, I notice slowdowns.
    My guess is that level 9 contains tons of hitscanners. And each shot creates a lot of particles.
    PrBoom
    You meant PrBoom-plus; regular PrBoom crashes on start when trying to play Hell Ground.
Sign In or Register to comment.