Into Spells and Research

Monolith Mondays No comments

monolith_death_v

Week 9 has ended and this is what I’ve been up to recently.

Since the combat was completed the first order of business was to implement event logs. Events are (so far) filed in two categories:

  1. Informative events, such as log in/out notifications, Neaya offers/rejects and similar, that are filed as a simple summary without geographical data
  2. Full events, that contain short and long versions of the report (such as combat or a breakdown of avatar effectiveness while influencing of a settlement) and locational data so “Go To location” is possible.

This now works and can be used to track major events.

After events I wanted to do something constructive but the dead private/empire chats were bothering me...

Read More

Combat complete!

Monolith Mondays No comments

dcs

Week 8 is over. It took a while, but combat is now finished. All avatars have their respective abilities implemented, and will fight alongside their armies.

Last post gave an example of what the combat log looks like, and with the new additions of avatar actions, it’s more polished in present form.

We covered the avatar specials in the last Monolith Monday but some small changes have occurred:

  • Haad avatars summon Tars Muna wraiths. How many, that depends on level and sheer chance (the essence of Haad is chaos after all), and the chance to control those wraiths depends on charisma ability. Otherwise, they might turn on the avatar’s own army. Or may not.
  • The wraiths eat life essence, represented by morale. The more morale one has, better chances of resistance.
  • Erol’s ability to steal enemy ...
Read More

Combat logs

Development Updates No comments

combat-log

I’ve been working last week on creating a combat mechanism that combined good sides of the original V2b6 combat alongside with the proposed V2b7 java DCS changes (from 2008). We now have a working prototype that handles all unit actions and gives an example what a 1-vs-2 combat looks like.

In this scenario Noble Jozo is beset by 2 avatars belonging to Noble Pero, each carrying a sizable army.

Noble Jozo has all his army on throne, with both his avatars also on the throne hex, though without any units. As a result Jozo’s battle stats are a sum of throne + avatar stats, and all the units and avatars (and Jozo himself) are merged into one supergroup.

Pero’s avatars are 2 hexes apart and for that reason cannot be combined into a supergroup nor combine their respective stats, and thus act as tw...

Read More

Designing combat all over again

Monolith Mondays No comments

dcs

Week 7 started out pretty pedestrian. I was rather annoyed that a player could still log in from multiple browsers/tabs and be treated as separate entity, and naively thought forcing a player out was a simple matter. Sure, server closed the connection, but the client didn’t just roll over and die – disconnected people could still open up windows with their clicks on other tabs where they were logged in, and chat with their literal selves and others. It turned out that the client’s design was a bit flawed and did not in fact track people by anything other than name. So, different tabs, different computers, it was all the same to the client – a player was a player was a player.

Once that particular issue was eliminated, rest of the week followed a simple routine – design a form, write JS to ...

Read More

Into Dominance internals

Monolith Mondays No comments

map-prototype4

Week 6 was a bit odd, if anything.

Good news: We have ticks!

Yes, they are manually executed, by design, automatic ticking will come later.

Writing the first tick ever took us into the realm of tick processing functions. For now, we have but a few simple ones – move avatars, increase populations, calculate draft pools, recalculate omnipresence from settlements and neayas. Nothing complex, yes, but even those functions call upon some of the more involved database operations. One in particular was how to update influences in elder-controlled settlements.

V2 had this work done in the database. There were some views, and some stored procedures that did work based on what the views were feeding them...

Read More

Fiddling with client

Monolith Mondays No comments

monolith_death_v

Welcome to the sixth Monolith Mondays update. Last week was all about the client. Sure, putting some images on the screen might not be daunting, but little features we take for granted like “zoom”, “move”, and “center” must have cost me half of the week’s productivity.

We have zooming now, with mouse wheel and dedicated zooming buttons. I have no idea how I’ll be able to implement this on a mobile client without a major overhaul of the entire client layout – which is what will probably be required – as there is not enough space for chat and the map and info boxes about map objects and elder information, all of which easily fits in the sidelines of a browser running on a desktop computer.

I’m not concerned about this yet, as there is plenty of time to polish the UI after the game skeleton ...

Read More

Map and vision

Monolith Mondays No comments

monolith_death_v

Week 4 has ended with development on a steady pace. First half of the week was spent porting a relatively old prototype map generator from its native (why of why) PL/SQL environment into the server itself, with speedups in 2-3 orders of magnitude. For more information on that, check out the last post which talks in detail about how the map is generated. Once the generation was complete, there had to be a way to send information about potentially dozens of thousands of hexes to the client, which in turn led to finding and fixing issue with the current implementation of telnet protocol in Python.

Naturally, telnet is not as trivial as a straight TCP socket dump, as the driver has to watch for special characters that signify telnet commands...

Read More

Mappifying Dominance

Random Ramblings No comments

The idea of a 3D map for Dominance is not a new one. In fact, work was done in 2009 to create a 3D map generator for Dominance that resulted in entity(Ther)’s master’s thesis¬† “Optimization of SQL procedures for accomplishing complex functions in real time” which is just a fancy name for “Reducing the bloody Dominance lag and calculating vision on a 3D map“. Naturally, entity(Huitz) had something to contribute, notably an application for generating height maps from the 3D map database as well as a crucial piece of code called ARCTANHUITZ that defines how soft the transitions between Vornoi diagrams must be.

For example, a generated height map could be represented into terrain like this:

heightmap3dmap

Note that this particular height map is some 1024 pixels long, and we will map those pixels to hexes a...

Read More

Creating Elders does require a map.

Monolith Mondays No comments

monolith_death_v

In the last week work was focused on getting a client up and running. Slowly the client learned to distinguish users, then to display their chat attempts, and finally to present chat interface in a respectable manner. After that the “create elder” form was finished, along with all the scripts required to validate input and prevent inadvertent errors.

It’s been fun. However, I’ve reached the point where all the niceties have been completed (server that speaks, client that can communicate) and it’s time to roll up the sleeves and dig into the database work. Let me illustrate what we have so far, generally speaking:

  1. Client says: Hi, my name is <username>, I want to join the game.
  2. Server responds: That is fine and well, I see you are a registered user, but you haven’t created your elder yet.
Read More

JQuery attacks!

Random Ramblings No comments

If there is something I never did, it was front end.

Oh sure, I have some knowledge of HTML (up to and including HTML4) and CSS (assuming CSS1)  but that is where I drew the line and never bothered to learn JS. The decision was perfectly fine, as it never came up so far. Having 15 years of frontend to catch up in not a small task, and certainly not something I would normally enjoy.

My fears have been somewhat abated once I was forced to dig into the client and create a presentation layer.

– “Google! Show me wonders!”
– “It’s 2016 and you still haven’t heard of JQuery?”
– “Uh, ok, .. JQuery! Show me wonders!”
– “Talk to my UI cousin.”
– “Um. JQuery-UI! Show me..”
– “Oh shut up already:”

chat

– “Wow, that was surprisingly painless, JQuery-UI.”
– “Meh.”

I can only say I had dreaded this part of ...

Read More