Development Blah

All other topics around Descent and D2X-XL

Moderators: Frustikus, simX, Aus-RED-5

User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

More DLE-XP

Postby karx11erx » Mon Jan 30, 2012 7:34 pm

Today I have been working a bit more on DLE-XP usability by adding more "spin controls" to dialogs where I felt they were making using DLE-XP easier and where I had missed them a lot in the past. A "spin control" is simply a pair of two small buttons with arrows printed on them. Clicking one button will decrease the value associated with the spin control by one, while clicking on the other button will increase the value (unless you fiddle with the control's behavior ...). Keeping one button clicked will increase the rate the value changes by changing the step width.

Since I am using this type of functionality at quite a few places, and since it follows the same scheme of tieing a slider, a spin control and an editable field displaying the current value, I have created a small class handling and synchronizing the entire behavior of the three controls. The class is flexible enough to support omitting one or two of the control types (i.e. it can also handle just a slider and a spin control, or just an edit field and a spin control). Implementing and debugging the class took a while, but the code is much more streamlined and easier to handle this way.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

D2X-XL and colored segments

Postby karx11erx » Thu Feb 02, 2012 12:31 am

D2X-XL supports the special segment types water and lava. These segments have distinct physics and visuals: The ship will slow down and move somewhat unstable in both of them and get constant damage in lava segments. Water segments will be tinted in blue, while lava segments are reddish. When adding the underwater area to the XL version of Wolfie's fabulous level "Swansong - Azure CATacombs" (ACAT) I found that colored segments weren't rendered properly anymore (or never at all for all render paths). I had changed some code to fix that, but today I found that my fix hadn't been working. Looking into the issue again revealed that there was a much simpler fix for the issue, and everything is well now.

This also means that the (hopefully) final version of Azure CATacombs XL is available now.

Alter-Fox's custom loading screens are hosted on my web server now (find them via the main downloads page). They are a great addition to the program and each of them gives another gameplay hint. D2X-XL will use them for other levels that do not have their own custom loading screen, and will cycle through the Descent 2 custom backgrounds for them, starting at some random offset to bring more variety into the loading process and show all the different information.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

DLE-XP: Convert Descent 2 levels to Descent 1

Postby karx11erx » Tue Feb 07, 2012 11:04 pm

Today Wolfie asked me for help with a small tool named 'TexFix' intended to convert Descent 2 to Descent 1 textures. Since I have no clue about this tool I directed her to this forum for help. I was curious though, so I looked into the attachments she had sent together with her request for help, and one of them was a list mapping Descent 2 to Descent 1 textures. Creating such a list is the biggest work for a D2 -> D1 level converter, and when I saw that list my subconscious started to work until a few pieces in my mind fell into the right places and I started to code a D2 -> D1 level converter for DLE-XP. It took me two or three hours, and the entire converter was done. :)

When converting a D2 level to D1, DLE-XP will do the following:

  • convert all textures
  • Remove all custom textures and custom robot settings
  • Delete all excess segments, walls and triggers (in arbitrary sequence, beginning with the highest segment/wall/trigger number)
  • convert segments and set all segments to neutral where there is no equivalent D1 function (e.g. goals)
  • convert walls if possible (transparent & cloaked -> closed with texture 'empty - light') and delete all walls that have no D1 equivalents (overlay)
  • convert triggers if possible and delete all triggers that have no D1 equivalents
  • downgrade all D2 super weapons to the base weapons (e.g. super lasers to standard lasers, helix cannons to spreadfire cannons, earth shakers to mega missiles)
  • Remove all excess reactors and bosses (leaving one of each)
  • Convert most robots that are not D1 robots to halfway equivalent D1 robots (guidebot and thief will be deleted, and so are most Vertigo robots)

If you find a bad texture mapping, feel free to propose a better one by sending me the D1 and D2 texture numbers (you can see them in DLE-XP's status line) in a feature request on sourceforge.net (please put all proposed mappings in one ticket).

I have tested this function with a D2X-XL level of mine (glass house) to have a real test, and it works great.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

New Worklog Article

Postby karx11erx » Thu Feb 16, 2012 5:25 pm

Check out my latest worklog article about DLE-XP improvements (some of which are still sizzling hot from the oven!). ;)
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

More DLE-XP goodness

Postby karx11erx » Fri Feb 17, 2012 9:08 pm

The particle and lightning effect tools now have a small box showing the color of the smoke or lightning the currently selected effect object emits, and you can also pick the color from the standard Windows RGB color picker dialog.

The level conversion tools have received a bug fix: Until now, light brightness and light color data wasn't properly converted when converting a D1 level to D2 or vice versa. This had the result that some textures started to cast light after conversion that shouldn't, while others that should didn't. This will now work as it should.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

D2X-XL, for a change

Postby karx11erx » Sat Feb 18, 2012 9:16 am

Yesterday I have been playing around with a D2X-XL detail a bit. In Descent, polygon model (e.g. robot and player ship) explosion clouds have the model stick half way out of them. Though this is not very apparent due to D2X-XL rendering them additively, I have decided to make this effect a little bit more realistic by moving the explosion cloud slightly towards the viewer during its lifetime, making it appear to extend to all directions from the center of explosion. Together with the blue shockwave effect, this looks quite convincing in my eyes now.

I hope that now that you know it, you will see it, too. :)

It's somewhat hard to implement this without expanding the object description, which cannot be easily done in the vanilla Descent code due to evil side effects that has (which I had experienced myself back in the dim and distant days where the D2X-XL code hadn't yet been class based).
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

Speed improvement

Postby karx11erx » Fri Feb 24, 2012 11:16 pm

Recently I have had e-mail contact with Grant Hallman, one of the level authors from the G.E.L.D. team (Grant Hallman, Lars Christensen and Robert Pedersen) who had built a bunch of top notch single player missions back in the day, which has inspired me to play a bit Descent and explore their levels again. The one I am fondest of playing is Minotaur, which mostly consists of a just perfectly executed, huge three story labyrinth.

Well, I am always the one to find the most D2X-XL bugs, so it seems ... :P ... and it proved true again here. There was stuff like

  • Areas behind walls that got removed during playing the level staying pitch black despite light sources being nearby
  • Environmental sounds (e.g. water) being extremely loud
  • Spawn markers being duplicated instead of relocated
  • The guidebot not properly staying away
  • The player ship changing its type back when being killed by robots after having changed it

Since there had been complaints about sound being too loud, I was glad I finally had a test case where this was reproducible. What confused me quite a bit during my tests was that the debug version of the program only ran the level at 4 fps or so. Unoptimized debug code or not: Given my hardware that was just too slow. When I looked into it I found a small design flaw in the sound processing's path finding I had made. I even remembered why I had coded it that way (both the obvious and the subtle reason causing it - I had just been too tired when implementing it). Changing two lines of code immediately raised the performance to over 80 fps.

Fixing the other issues listed above was of course desirable, but not crucial. Fixing the path finding certainly was, and particularly players with slower machines should feel the impact quite a bit, and maybe finally find D2X-XL to be playable on their machines, too (hint, hint, Wolfie! ;)). Another side effect was that sound handling and distance dependent decay now seems to work properly. The only backdraw is that some fixes also affect visibility and lightmap calculation, so all related data needs to and will be recomputed by D2X-XL. I will start to update the precomputed light, mesh and lightmap data hosted on my website soon though.

Something I also took care of was sound building up extremely if there were several sound sources in a segment (e.g. flowing water on four of its sides). D2X-XL will now scale the volume of the individual sound sources down to decrease the total volume to an acceptable value.

In the course of my tests I even created a new cheat marking a path from the current player position to some other segment in the level, which I aptly and in honor of the fabulous maze mission "Minotaur" I had mentioned above labelled "minotaur"; so if you type in "minotaur", a dialog asking you for the destination segment will pop up. On closing it, a path of energy boosts (which cannot be picked up and will disappear after a while) will lead you there.

The rather limited range of the Guidebot of 200 segments from its current position has also been extended to 1000 segments, meaning that you have better chances to have it find stuff for you in huge mines like Anthology. ;)

So I hope that many users will find this upgrade particularly useful and enjoyable this time. Have fun. :)
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

DLE-XP enhancements

Postby karx11erx » Wed Mar 07, 2012 4:48 pm

DLE-XP has gotten some development love again ...

One addition made due to a request by Hawkins is that variable (blinking) light information will now be stored in extended block files. I used a little dirty trick to keep the format compatible to older extended block files.

Another, bigger enhancement I finished today is the ability to split a segment evenly in eight smaller sub-segments. This can be done for a bunch of segments at once; they just need to marked ahead of launching the operation. The newly created smaller segments will be properly joined with their environment as far as possible. The main purpose of this function is to allow for quick refining of coarsely built areas (like e.g. the outdoor area of the Volcano level from my mission Warp Shockwave). This way you can e.g. build a quick prototype or rough outline of a mission and refine it later on with little effort. In my case I will use the function to split the outdoor area's overly huge segments into more manageable chunks.

I will do some more testing with the function before making the DLE-XP update publicly available. Stay tuned. :)
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

More DLE-XP ...

Postby karx11erx » Wed Mar 07, 2012 11:44 pm

The testing has been done, and boy, were there still bugs ... :shock:

The feature now works very well though, and I have already treated the entire outdoor area of said Volcano level from Warp Shockwave with it.

I could also nail down Wolfie's ominous "all robots turn into Spiders" bug - the diagnosis function was the culprit. The bug was introduced by a recent change I made to the function.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

D2X-XL for a change

Postby karx11erx » Thu Mar 08, 2012 8:07 pm

Today I have been able to fix a bug that has been haunting D2X-XL for years, and that is the ability to pick up powerups that should be inaccessible to the player because they are locked away behind gratings or walls. The best known manifestation of this bug probably was being able to grab the full map powerup in level 2 of Descent 2:Counterstrike.

A bug report by Obi made in a comment about my D2X-XL conversion of Gengi's nice map Shaker Henge had led me on the right track: Here the player could grab earthshakers that were locked away behind transparent walls.

This was an nasty one; and it's finally been squashed. :laola:
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

Re: Development Blah

Postby karx11erx » Fri Mar 09, 2012 11:13 am

Soooo ... my fix didn't really fix anything. Instead, collision handling didn't work right anymore at all. After my fixing the fix, the "grab powerups through walls" bug was back.

So I took some more time to look into this, and even debugged the old D2X-W32 version I am still keeping as reference for cases like this one. After diligent examination of the code I have come to the following realization: Actually D2X-XL does it (at least half) right here, and all other Descent version tend to do it wrong.

Why?

D2X-XL is the only Descent version not only examining the player segment, but also that segment's adjacent segments for collisions. This has been implemented as a fix for fusion blobs not hitting objects not in their home segments although the blobs touched the objects. That fix had been necessary because objects can extend past their segment's boundaries (the "home segment" being the segment the object's center is located in). Descent never took care of such cases. D2X-XL does.

Now both the full map, and as in the current case of Gengi's map Shaker Henge, the earth shaker powerups stick out of their home segments. Descent will pick up a powerup as soon as the player's and the powerup's hit spheres touch each other (the hit sphere being the smallest possible sphere completely enclosing an object). Of course it still holds true that the object should be able to move through a solid wall to the player ship, even if the ship can touch it, so I will make sure that objects behind impassable walls cannot be picked up even if they can geometrically seen be touched.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

Visual Studio 2010

Postby karx11erx » Fri Mar 09, 2012 2:31 pm

The last days have seen me trying to create a fully working install of Visual Studio 2010 Ultimate. In the process I have uninstalled and re-installed it two times, and have tried a repair.

No dice.

When opening a .NET 4 C# project in debug mode an target 'x64' or 'any CPU' I am told that the ProteusDebugEngine debugger cannot attach to the project's process. Funny enough, this does not happen with the VS 2010 Ultimate install on my notebook (which has a pretty similar general software setup as my main machine).

So it looks like I will have to flatten my Windows 7 installation and reinstall it to resolve whatever causes this goof up.

Thank you, Microsoft. You sure know how to make people happy, do you? :rant:

Well, the main reason not to plug a SSD in my computer as boot device was that I didn't want to reinstall Windows 7, so what. Just purchased a nice SATA 3 SSD and a SATA 3 + USB 3 adapter. :D
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

Galactic Event IV

Postby karx11erx » Sun Mar 11, 2012 12:01 pm

Well, yesterdays big D2X-XL multiplayer "Galactic Event IV" turned out to be a rather "Solar System Backyard Party". Most of the time I was trying to track down a really nasty bug where the game was crashing when a player died or tried to join. At least I managed to finally pin it down and fix it.

Another bug where OS X users are invulnerable to kinetic weapons in multiplayer is still unresolved. simx has however been so kind to help me in debugging into this, and we have had the bug in arm's reach already when he had to leave due to rl obligations. D'uh. :?

We played Azure Catacombs XL a lot of the time, and while I have to say that it looks fabulous, it is way too huge for Descent (2) multiplayer in my opinion. The dimensions are more geared towards D3 and its significantly faster movement speed.

This has given me a new idea though: A turbo mode where everything moves faster! The speed will be scalable in several steps (how many and how big they still needs to be determined and tested), but I think this might give gameplay an interesting twist particularly in huge, spacious maps - and maybe even draw one or the other D3 player to D2X-XL. We'll see. :)
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

D2X-XL Improvements

Postby karx11erx » Sun Mar 11, 2012 2:54 pm

Today I have added two D2X-XL improvements. One of them is a security measure, while the other is a nice goodie.

The security measure means that D2X-XL is now checking the version of the extra netgame data D2X-XL uses for telling multiplayer clients D2X-XL specific settings (like available effects, missile capacity, etc.). Until now, changes in that data had the effect that clients using older program versions received messed up D2X-XL settings (which could e.g. result in loadout limits not being effective for them).

D2X-XL will now make sure that every multiplayer participant uses the same extra netgame data version the game host does. This doesn't mean that with every new D2X-XL version, older versions will be rendered incompatible. Actually the extra netgame data changes very rarely; if it does however it has a significant impact on multiplayer gameplay - that's why I decided to introduce this version checking.

The goodie is that you can scale the overall game speed between 100% and 200% now (in 25% steps). This is a new challenge for versed players and can also be very fun for everybody. It also can be a cure for huge multiplayer levels that until now felt too slow for regular multiplayer games. Maybe this feature will even draw some D3 players to trying a D2X-XL game from time to time.
User avatar
karx11erx
D2X-XL Master
D2X-XL Master
Posts: 8112
Joined: Mon Sep 24, 2007 8:48 pm
Location: Wilferdingen, Germany
Contact:

C# rant

Postby karx11erx » Mon Mar 12, 2012 11:20 am

I have had some time to gather some extensive experience with the latest generation of Microsoft products (the "2010" releases).

None of them work right, or well.

MS Word 2010 does weird things with globally defined formats, and gets extremely slow when there are a few drawings made using the built-in symbols in a document (I have a document with a few simple network plans as template for exercising manual network plan calculation, and paging down two or three pages is not just a slideshow: It's actually an exercise in patience, waiting for the computer to update the screen at all, and this on an overclocked Core i7 920 with plenty of highspeed memory and a really fast graphics card!)

MS Project has so many bugs that there is a book about them, and how to avoid or work around them (no kidding!).

MS Visual Studio has exposed a bunch of quirks already to me after only two days of using it.

What is the quintessence? C# is the new Basic, and it is evil!

Why?

C#'s premise is to make coding simple and code safe. The goal of this is to increase productivity and software stability. We need to translate this to make it understandable: With C++, if you goofed up, the software exploded right into your face (and so did eventually the customer). This forced people into really understanding what they did and not rely on tools too much when it came to software robustness and quality. With C#, every idiot (so to speak) can create a program that will work somehow (because the IDE already fixes, or helps to fix, most of the bad cases of buggy coding). The problem is that enabling an idiot to code this way doesn't make him capable of creating good, well structured, fast code.

Which makes me turn to a side rant about diplomas and master degrees.

I have seen too many people with a computer science uni diploma or master degree who were crappy programmers. The reason probably is that there are too many who want to achieve a master's degree and are permitted to universities. Equal chances for everybody, eh? In Germany particularly with it's three tier school system this means that everybody tries to avoid their children having to attend the lowest tier schools (Hauptschule) and if ever possible get them into the highest tier (Gymnasium, which roughly translates to a high school, but has higher requirements). So you have a mass of students who inevitably have a lower average intelligence than let's say 50 years ago, where only a few percent of high school graduates started a university study. Another effect is that you cannot offer so many subjects for high quality diploma thesis. In the end this means that the diploma standards have deteriorated.

Back to C#. Add the two rants together, and you'll understand why the new generation of MS products is crap. It's cheaper to hire young programmers and have them slap something together some way that will work somehow (thanks to C#), than have expensive experts who are able to create something worth our, the customers, money and time because they know what they are doing and can handle a programming language allowing them to do what is necessary (nobody is forced to create crappy and/or unreadable code with C++).

As it is now, the good (a.k.a. experts) get less and less and create stuff like HTML 5, WebGL and high quality frameworks, while the bad and the ugly (noobish and incompetent mass of programmers) use their tools to create messed up end user software.

Bleh.

Return to “General Discussions”

Who is online

Users browsing this forum: No registered users and 0 guests