A Knight's War - Code A Game Competition 4th May to 30th June - Retro Strategy

Started by Matty, May 08, 2018, 10:44:21

Previous topic - Next topic

Matty

I've chosen the 'retro strategy' option for my game.

I think I'll actually put something together this time - and it should be fun to make something.

I worked on the code and graphics for this before/after work today for about 3 hours so far.
http://www.mattiesgames.com/retrostrategy/

It's going to be a turn based strategy - a single battle on a map between two opposing forces of about 8-12 units per side.
Units will have the following categories:
Heroes
Magic Users
Basic Units

with their own stat profile and so on.

I've worked out most of the design on paper and am now in the implentation phase of the game.

It will be single player against the AI and two player hotseat mode.

There will be two factions (original design was going to have four but I doubt I'll have time to put together four whole factions in a decent level of detail before the comp end)

The factions will be good/order/light versus evil/chaos/darkness....

I will draw up some new sprites especially for this game.

I'm not planning on having any sound because I hate sound on webpages and it's so hard to get right. (Sometimes sound plays and sometimes it doesn't).

Matty

Being web based all source code will be available since I can't hide it!

iWasAdam


Matty


Xerra

Very interested to see this one come together. What language are you writing it in? Are you going web based deliberately or is it just to ensure you don't have to deal with build issues to cater for PC/Mac/Linux/Ron etc? :)
M2 Pro Mac mini - 16GB 512 SSD
ACER Nitro 5 15.6" Gaming Laptop - Intel® Core™ i7, RTX 3050, 1 TB SSD
Vic 20 - 3.5k 1mhz 6502

Latest game - https://xerra.itch.io/Gridrunner
Blog: http://xerra.co.uk
Itch.IO: https://xerra.itch.io/

Matty

Hi Xerra...it's straight plain old 'javascript' written in notepad++ editor.

There will likely be some php back end (for the AI - I have an idea for another learning AI that improves over time as users play it) but I may or may not share that particular piece of code.

Reason for web language:

I had three options (due to knowledge limitations on my part)

blitzplus/3d (windows executable)
javascript (web)
java (android)

Android is too messy to get anything simple done and I despise google after the way my other apps have been handled by them.

blitz is a deadish language and it does me no good to learn a lot from it - but also limiting myself to windows only..I might want to play on my phone which a web version will still allow.

Web is compatible with more devices, should I write it properly, than the other two...and is a skill that's useful to keep fresh on. I've already learned a few things as I've coded parts of it.


Matty

It's coming together..bit by bit....

next step to implement some special abilities for each of the units....


MikeHart

Interesting. In which way do you plan to serve the retro aspect?

Matty

Retro features:
Mainly that it is similar in style to a lot of 80s strategy pc games (master of magic etc), uses an old leyter box format 4:3 aspect ratio, is turn based not real time - those are the main bits.

Derron

People here - and in other places, understand "retro" as low-res graphics, chiptune sounds, ... So limiting gameplay to be "retro" might not be what they expect.

Dunno the expected maximum resolution but if it fits into "PAL/NTSC" then it might fulfill at least something similar to 2nd gen consoles (mega drive, SNES, ... - which had a different resolution nonetheless). And colors would be <256 (no alpha transparency - except you map the resulting color to your palette).


bye
Ron

Matty


iWasAdam

Don't take it to heart. think of it as a challenge...

lets just say your maximum resolution should be limited - definitely no larger that 1024 - think 800x600
and also think about using a restricted palette (as Derron suggested) < 256

So you game itself doesn't change - it's the graphics that need some attention to more fit with a retro style.
E.G.
reduce the colors and use a consistent palette across all graphics. you could do this simply by using some form of sprite atlas (where all graphics reside in one large graphic). It is then a simple task to reduce the colors to a single 256 palette :)

a quick google for "retro game graphics" should make things a bit clearer :)

LoRes LoColor is the look you should be heading for

another thing to check out would be "amiga game graphics". this is definitely worth it as you will get a feel for how most 16bit system look and feel <-there is a style and look here ;) Amigas are more interesting as they used samples instead of chiptunes, but again had limited capability so had a certain vibe going on with them.

Matty

Okay....for a more retro look - I've passed this through a filter (downsampled by half then reupscaled but using the brightest pixel colour as the dominant pixel colour ... )

How does this seem for a more retro look:



pseudocode:
loop through all pixels in steps of 2
get brightest pixel in each of 4 (x-1,y-1 to x,y)
apply brightest pixel to all 4 pixels on upscaling.

Get a nice retro looking effect...

(this won't be real time..I'll have to redo the images through a java program I'll have to write later)

Derron

Do not automate processes - It looses a lot of contrast - all colors look a bit "washed". While the bottom-center units look good (ignoring the contrast for now) the units on top expose the flaw in your approach: blue+brown pixels without distinguishability - what is that most left (top) unit? what is that gray+red thingy? Maybe the bottom units are better recognizeable as there are less per "group" - and they are standing more "apart" from each other (contour-wise).


bye
Ron

Matty

I might use the filter as a first pass and then manually edit the images generated.