• Register

Why is your programming so bad?

RSS Reviews
6

Mount & Blade: Warband - Viking Conquest

Game review

Dear Players, Community members and other fans, I was quite excited to get my hands on the new DLC, But I am now very disappointed in it’s quality.

I spend some time in the Source code of the module (decompiled it) and the BRF files and I can only say that I’m CRYING, how can they release it in this state, and expect it NOT to crash and bug is beyond me.

Main reasons for warband engine to crash: errors in BRF files, High memory usage.
Main reasons for low performance: Bad code, oversided textures and sounds, LOD nonusage.

The Brytenwalda team is to blame for these problems, NOT TALEWORLDS!

Following are the things I shall lay out as problematic that need sorting out ASAP. Keep in mind that I only took a quick sweep over the files and that I most likely did not list everything.

1. General Reminder
2. Script/Module System
3. BRF Files (Using OpenBRF to view them)
4. Textures
5. Sounds

1. General Reminder
Mount & Blade engine loads everything into memory at startup! That means that EVERY single texture, sound and mesh will be loaded into memory. OGGs and brfs. will be unpacked and will become MUCH larger than on your disk.
Also keep in mind that Warband is a 32 bit engine and can only load up to 2000mb into memory. As soon as you go over 2000 megabyte, it will crash!

2. Script/Module System
First of all after opening the source code after decompiling, I got quite scared of the massive amounts of it… anyway I started reading through multiplayer code only because this is the thing that is the most messed up at this time as far as I know.

I shall lay out a couple of topics I want to talk about.

2.1 Performance
In multiplayer, with many players, performance is crucial,
First of all, there are many mission templates, running, often, maybe too often, those will suck up CPU performance, the oh so important performance factor for dedicated servers… please check all template timers and make sure they need to be this often.
Next is the containing code itself, I see many times killing loops in loops, for instance a for each agent in for each agent loop. This is a killer, especially when ran often, with just 10 players you will execute code 100 times, with 100 players the code is executed 10000 times, you can imagine the strain on the server cpu.
Your sea shader change and time code is ran all the damn time even when not needed, 40 times per second really?
There are many more cases, think of horn code checks every frame, etc etc, its a mess.. sort it out!

Networked events… I see so many ints flying left right from and to server, are they really needed? so many? events are heavy, they are secure send, resend and so on, this is a easy killer to networked performance, reduce the events, many things you're sending is already available to the client, for instance his damage and other things…

Overall, cut down on useless code, get rid of straining loops with better architecture, reduce networking events that are not needed, its better sending one event with 4 ints than 4 events with one int! I can rant on but this is so obvious to me… Just, go through the code and think. can this be better..

2.2 hackpositiblies
Maybe even worse than performance, Hack possibilities, I don’t want to give too much ideas to people going to exploit things, but lets just say that many of your bonus abilities, checks and other things are client side only, meaning people can change the code and get rid of many safe guards, think about horns, beserkermode and i think i already said too much, please check absolutely everything a client sends to the server double!, this is so easy to hack right now I’m crying.


3. BRF Files (Using OpenBRF to view them)

3.1 BRF Errors
First of all, I found several errors in the .brf files. Please fix ALL of the following 606 errors and warnings.

Here is a link to a PasteBin due to otherwise exceeding the maximum number of letters.
Paste.ubuntu.com

I think these should be pretty clear. Please contact me if yo