Ultimate Wars (Updated 6/30/2014)

Hey guys,

A long time ago, a little over a year ago, I decided to make a sort of army simulator but it would include various warriors and monsters. The idea was that they would fight one another and whoever won would be superior to the other. So I built the basic framework but i then abandoned it because, well, I started on Astrofirm. Well today, I took on the task of making it into something. That thing is what I am showing you today. It is made with Java2D LibGDX so I decided just to draw units as basic shapes in order to save on performance. Anyway here it is:

Screens:

Download Here

Enjoy!

Controls:
WASD- move the camera
Q- bring the battle edit window back
Space- pause / un-pause the game
T- Toggle Unit AI between new and old
R- Toggle between new and old textures (no performance improvements)
Left Shift- Slow Motion

I forgot to mention that the battles are generated randomly according to the settings and values you put into the Battle Options window. There are currently 3 battle types: Cluster, Random, and Four corners of death. And there are 5 unit types: Human, Zombie,Ogre,Ninja, and Death (warning: Death units are so overpowered that it takes a large group of other units in order to take one death unit down. Use responsibly :wink: )

There are also some blood options

V 2.6:26:14.11:24
CHANGE LOG:

  • Switched to LibGDX
  • New Unit and Blood textures (can switch back to blocks by pressing “R”)
  • New Unit AI (Can switch back to old AI because the new one makes things less exciting but more realistic note: both AIs need improvement)
  • Added defaults to the Battle Options window
  • Slow Motion
  • Bug Fixes

V 3.6:30:14:7:56
CHANGE LOG:

  • Create and load Units via XML
  • Betterish Ai
  • Updated GUI to better fit the xml loading

Very nice - you should add a speed toggle so you can slow down/speed up the simulation as you please.

You know I was thinking about doing that too. It will probably be in The next update

that was more entertaining that it looked lol. It could do with some default settings, its hard to work out some of the limits. now you just need some terrain obstacles, some goal and method of scoring (place certain amount of zombies in certain designated areas to try to kill the orges, etc) use your ponts to buy more mobs to place lol. it could make quite a nice simple strategy game without even any graphics.

V 2. 6:26:14.11:24
CHANGE LOG:

  • Switched to LibGDX
  • New Unit and Blood textures (can switch back to blocks by pressing “R”)
  • New Unit AI (Can switch back to old AI because the new one makes things less exciting but more realistic note: both AIs need improvement)
  • Added defaults to the Battle Options window
  • Slow Motion
  • Bug Fixes

Updated Controls:
WASD- move the camera
Q- bring the battle edit window back
Space- pause / un-pause the game
T- Toggle Unit AI between new and old
R- Toggle between new and old textures (no performance improvements)
Left Shift- Slow Motion

Download Here

really funny =D

I had a really bad crash the first time that I couldn’t reproduce.

I clicked generate battle and the game stopped responding.
I tried to switch to it but the battle options window wouldn’t let me. I also couldn’t close the options window.
I tried ending both processes but they wouldn’t end.
I then had to terminate javaw.exe and spam the “close window” popup until they both closed.

Like I said, I couldn’t reproduce but it the worst Java crash I have ever had.

Now that that’s out of the way, cool simulator. I couldn’t tell a difference between the new and old AI though. Do they just perhaps not clump on one target? I lost sight of the battle sometimes, maybe you could have a “reset camera” button which would zero it.

Edit: Also, when most of the creatures were killed of, they just separated and didn’t move. Maybe other things weren’t close enough to them to trigger chasing?

Thanks for the kind words ;D,

I have experienced that crash a few times (about one in every fifty or so launches) but everything is seemingly fine in the console. I can’t pinpoint where it could be coming from and I also can’t reproduce it so I can’t fix it right now , but I will have to.

The AI is very buggy right now but the two are a little different. In the Old AI you should see more blood centered around the North East and South West diagonals of the Battlefield bounds but with the new, blood is more spread through out the whole area.

The whole stopping thing might come from two things: first, the Ai just gave up or second, a ninja paralyzed that Unit. Basically, each Unit has an effect than they can perform on other Units about 3% of the time when they attack: Zombies can turn Humans into Zombies; Humans can cure Zombies and make them human; Ninjas paralyze their foes; Ogres get Higher attack and movement speed; Death units get nothing because they are way too overpowered as it is.

add more stuff to it i enjoyed play this xD add like battels

so you are one team and you gota fight others and kill all of em and you can like upgrade weapons and armor and stuff
like an rpg or something

EDT: hit me up on skype: tomastero

and we can talk =D

Example of a Unit XML file:



<?xml version="1.0"?>
<config>
	<unit id="2">
		<name>Ninja</name>
		<speed>2.5</speed>
		<defence>15</defence>
		<attack>15</attack>
		<swing>15</swing>
		<range>25</range>
		<regen>.01</regen>
		<red>.5</red>
		<green>.5</green>
		<blue>.5</blue>
	</unit>
	
</config>


If you have any suggestions please feel free to say them.

@VIrtueel
I like those suggestions, they will probably be in a future update after I add vague army control. As for Skype, i don’t like to give out my Skype, but if you really want to talk, I’m like Google Hangouts. Be warned though, I only message people because my house isn’t exactly quiet and you can get the point across much quicker in messages. (plus, there are emojis ;D!) Google+ Page :point:

How about something like this?



<?xml version="1.0"?>
<config>
	<unit id="2" name="Ninja">
		<speed>2.5</speed>
		<defence>15</defence>
		<regen>.01</regen>
		<weapon attack="15" swing="15" range="25"/>
		<color r=".5" g=".5" b=".5"/>
	</unit>
	
</config>


If you are using DOM XML, then reading XML like this is very easy and extensible - for example, you can have Color class with constructor Color(Element) which read color data from Color element - the same with weapon and unit itself (I had no idea for speed, defence and regen).

This way, if you stick to this scheme, you can for example use element in any other entity informations.

How about something like this?



<?xml version="1.0"?>
<config>
	<unit id="2" name="Ninja">
		<speed>2.5</speed>
		<defence>15</defence>
		<regen>.01</regen>
		<weapon attack="15" swing="15" range="25"/>
		<color r=".5" g=".5" b=".5"/>
	</unit>
	
</config>


[/quote]
Ok, I have set up the xml parser to use that format, thanks. I though that the original was very ugly so this was helpful ;D
[Edit]
I am working on a way to dynamically make/load mods. Wish me luck! update after this is done!

Really unique, reminds me of supersmash bros. I thought the AI could have been improved a bit, they move pretty fast.

Woo new update!
V 3.6:30:14:7:56
CHANGE LOG:

  • Create and load Units via XML
  • Betterish Ai
  • Updated GUI to better fit the xml loading
  • Default Unit installation

You can now load Units from .xml files! All you have to do is after running the game at least once, go to the Ultimate Wars folder in your AppData. Once there go into the Units folder and there ya go. Just add an xml file that follows this format and put it into that folder or just edit a file that is already there:


<?xml version="1.0"?>
<config>
   <unit id="2" name="Ninja">
      <speed>2.5</speed>
      <defence>15</defence>
      <regen>.01</regen>
      <weapon attack="15" swing="15" range="25"/>
      <color r=".5" g=".5" b=".5"/>
   </unit>
   
</config>

DOWNLOAD HERE