Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Tier1 Basic RTS Framework [code]

Author
Message
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 14th Feb 2017 18:52 Edited at: 17th Mar 2017 08:42










Hello pals,

recently I started my journey to Tier 2 valley, and recognized, that I have so little time to spend on my other small projects.
I thought, I could share them with you. This thread is dedicated to RTS.

A gui, that can be written in XML files reduces all problems:
Download:
https://forum.thegamecreators.com/attachment/78865
This code helps to create a decent GUI.



I am a big fan of the old real time strategy genre and was always fascinated by the clock-wise semi-transparent building progress sprites in the gui.


Download:
https://forum.thegamecreators.com/attachment/78595
This code contains a pixelshader, that can do the trick. You just have to input a float from 0.0 to 1.0 to set the progress state.




No real RTS without fog of war 'fow':


Download:
https://forum.thegamecreators.com/attachment/78597
This demo contains all shaders and functions to create a 2d/3d fog of war. To see it in action, download the main code.



If there is more interest in developing a community based RTS system, I could also release the whole Tier1 Framework:

With Basic A* AI, healthbar shaders, terrain collision and stuff...


EDIT:
My current RTS attempt can be found here:

Download:
http://movies.online-arts.de/Files/RTScameracontrol.zip



It would be great if someone could figure out a simple, but effective method to command over 100 units at a time without a AI-Delay.

And also a Json Style Definition of all models/ units/ etc... like the rules.ini in command and conquer.
I have a lot of artwork to contribute to this project. But first there should be some kind of model-editor, where you can test the model coming from
a 3d program. We also need proper definitions for all unit types, that should be added into the model file format, for example a tank should have a
turrent, lights and maybe slots for upgrates. This should be defined inside the 3d model itself, so the model-editor will know how to display them.
If the Model-editor is done, it should be easy to implement the handling system into the engine.

If these points will get done, I will dump a massive collection of buildings/units/ trees/ rocks, most of them are made by myself the others are from the Dark Basic Classic media collection/ DarkMatter. So we would have a good starter kit for two fractions.
Every time something useful is contributed, I post some of my special game models, royalty free.



Open work:
Efficient 3d Particle System
Volumetric Fog Shader
Waves Effect
Projectile Simulation
Bezier Flightpaths for airplanes (already added the advanced math functions, there is stuff in it to get this to work)
Light/ Shadow System?
3d Sound System
Weather Effects Shader
Aircraft movement code
Procedual spline Roads, that can be generated after placing some waypoints. They should fit the terrain.

And also the standard stuff like media management, smart culling etc...

[/url]

Attachments

Login to view attachments
Phaelax
DBPro Master
16
Years of Service
User Offline
Joined: 16th Apr 2003
Location: Metropia
Posted: 14th Feb 2017 20:46
I'll be sure to check this out later when I'm home.

Quote: " clock-wise semi-transparent building sprites in the gui."

No clue what you mean here.

"I like offending people, because I think people who get offended should be offended." - Linus Torvalds
Ortu
DBPro Master
11
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 14th Feb 2017 23:23
Indicates build time/progress or ability cool down.

The icon starts off greyed out then animates a clockwise reveal to full color
http://games.joshkirklin.com/sulium

A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
Mobiius
Valued Member
16
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 15th Feb 2017 09:08
That looks pretty good!
CJB
Valued Member
15
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 15th Feb 2017 09:40
That looks REALLY good! You've obviously put a LOT of work into it. Push it to a full game Jack. Looks like it would be real quality.
Blendman
5
Years of Service
User Offline
Joined: 17th Feb 2014
Location: Arkeos
Posted: 15th Feb 2017 13:05
could be great to have a 2D version .
AGK2 tier1 - http://www.dracaena-studio.com
Green7
13
Years of Service
User Offline
Joined: 23rd Nov 2005
Location: Switzerland
Posted: 16th Feb 2017 07:38
This looks like something i would support. i am not a real good coder, but if you need some 2d or 3d stuff, then i may be able to help.
hoyoyo80
3
Years of Service
User Offline
Joined: 11th May 2016
Location:
Posted: 19th Feb 2017 07:13
lack of rts on mobile. Should be great
Sph!nx
10
Years of Service
User Offline
Joined: 3rd Dec 2008
Location: The Netherlands
Posted: 19th Feb 2017 14:08
Looks very cool. Nice work!
Regards Sph!nx
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 24th Feb 2017 21:02 Edited at: 25th Feb 2017 01:54
Thank you guys!
I hope someone is capable of adding a new AI system, that is more efficient with 100+ Units. And a object loader routine would be fine aswell.


I have little spare time right now and an enormous working stack.

Here is the main Tier1 code, have fun!
http://movies.online-arts.de/Files/RTScameracontrol.zip

I have found some old game art related to this project, I add it in the first post.
Does anyone remember these models?

[/url]

Attachments

Login to view attachments
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 24th Feb 2017 21:47 Edited at: 24th Feb 2017 23:32
If you try to build up a model-editor,
check out the attached code. there is a very handy 3dsMax Style orientation selection function.


Ive found more render stuff, project related:





Maybe we also need some script stuff like that:

This example code builds a simple script and can also handle them.

[/url]

Attachments

Login to view attachments
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 11th Mar 2017 13:08 Edited at: 11th Mar 2017 13:09
I have created a whole HUD and window management lib based on the wonderful Marble X GUI lib.
Now the window creation is no problem at all. I will try to update this into the current public version soon!


[/url]

Attachments

Login to view attachments
easter bunny
6
Years of Service
User Offline
Joined: 20th Nov 2012
Playing: Dota 2
Posted: 11th Mar 2017 23:27
Looking awesome!

My Games - Latest WIP - My Website: Immortal.Digital - FB - Twitter
130,000 installs with AppGameKit and counting
Jeff Miller
14
Years of Service
User Offline
Joined: 22nd Mar 2005
Location: New Jersey, USA
Posted: 15th Mar 2017 00:15
Thank You! This is one of the most prodigious code submissions to the forums that I've seen in a decade. The extended math library alone is impressive. (Am I correct in assuming wrapvalue() is used when you know the argument is positive, and wrapangle() is used when you are unsure?)
zxcvbnmy
2
Years of Service
User Offline
Joined: 17th Feb 2017
Location:
Posted: 16th Mar 2017 06:56
great!
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 17th Mar 2017 08:11 Edited at: 17th Mar 2017 08:40
Quote: "This is one of the most prodigious code submissions to the forums that I've seen in a decade."

Thank you! I thought it was not noticed^^

Quote: "The extended math library alone is impressive."

Thank you! This library made a lot of stuff possible and is right now the gold-standard for AppGameKit Tier1 matrix math, until TGC releases the commands in T1.
Quote: "
(Am I correct in assuming wrapvalue() is used when you know the argument is positive, and wrapangle() is used when you are unsure?)
"


wrapvalue is used if you want to interpolate between a single, linear value, for example to inperopate from 1.0 to 100.0.
wrapangle is used if you want to interpolate between two angles (0- 360, where 360 = 0)

The main use for wrapangle is for example, if your player points to one direction and you want to interpolate (smoothly rotate) the player to a new direction.



EDIT:

I have attached the XML GUI Library based on MarbleX GUI! Hardly commented and not up to date, but it works.
I would recommend you to change the old ImageFont System to the new native Font System, in Order to get even better results.
But the XML stuff works, so we should be technically able to create the main GUI for a RTS game.

all the Windows XML files are inside "Media\core\windows
"

To load a Window in agk, "win_play=mx_create_window("level_play.def")"



The attached project can also be used as a nearly finished level editor for this RTS..

[/url]

Attachments

Login to view attachments
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 17th Mar 2017 12:36 Edited at: 17th Mar 2017 12:41
I add my previous billboard shader to this thread, because it can also help to reduce the polycount on large map overviews, and is useful for this RTS project:



I had an auto-billboard renderer for AppGameKit somewhere, maybe I can find it..

[/url]

Attachments

Login to view attachments
Jeff Miller
14
Years of Service
User Offline
Joined: 22nd Mar 2005
Location: New Jersey, USA
Posted: 20th Mar 2017 13:41
On the RTS Camera Control module, when I switch to full-screen mode by pressing F4 the terrain vanishes. The units are still visible and I can move them properly, so I suspect that the problem does not involve the camera. Also, when I press F4 again to return to the built-in window size, the terrain returns. Any suggestions? If it helps, I'm using windows 10 and my full-screen is 2560 x 1440.
Jack
14
Years of Service
User Offline
Joined: 4th Oct 2004
Location: [Germany]
Posted: 24th Mar 2017 00:08 Edited at: 24th Mar 2017 00:09
Hello Jeff,
I confirm this bug and think this is made by the 2d viewmap rendering pass.
I recently came across some problems between switching to fullscreen or window in all of my apps, that are using rendering operations. There are some screen dimensions that are not passed correctly, when changing the resolution. I don't know how to fix this, maybe I have made some misstakes in the rendering pass, technically it should work.

[/url]

Login to post a reply

Server time is: 2019-07-17 05:20:56
Your offset time is: 2019-07-17 05:20:56