I worked a lot on the script system, and managed to expand some more on particle functionality. Now the particle and technology data are passed in to the script from xml files, allowing you to specify custom values in either file.
I also fixed some bugs and improved the speed of scripts. There's no ship collision yet, that's next after I finish the firing delay between each mount, and particles that live for more than one turn.
Now, here's a video demostrating three different beams: Laser (instant), Plasma (slow traveling beam), and Ion (fast short beam). Plasma and Ion both use the same script file, but has different custom data. Laser uses a different script due to it being drawn its full length.
Watch here!
As you can see, there won't be much difference between Beam and Projectile weapons, just that Projectile weapons have a limited ammo.
Whew, that's a lot of work done, hopefully I'll have some more free time later this week!
Looks nice, players will love this!
ReplyDeleteWill there a alternative way for selecting weapons? Something like keyboard shortcuts, FPS style :)?
Thanks, I hope players will like this too!
ReplyDeleteI might consider that, right now I'm just trying to get it all up and running. Then I'll look at improvements.
Looks nice... Question though, if it is going through the front and rear shields, is it also going through the ship, or is this passing underneath and we just can't see it? :)
ReplyDeleteRight now, it only handles collisions between particles (beam, projectile, etc) and equipment (shield, armor, etc) that don't involve the ship itself. After I'm done with the new spawning mechanisms (allows you to spawn more than one particle at a time, and to have delay between each particle), I will then work on the particle vs ship collision which will involve taking damage and ship dying.
ReplyDeleteIt already detects collisions between particles and ships, but it's not being handled right now. I will need to add scripting for the ships themselves, which requires a bit of reworking of the race data.xml file so that each ship can have its own script. The basic ship script will work for all the ships at this point, but if you want a race that have ships that heal themselves automatically, you can create a new script and reference to that in the race data.xml file.
This ship script system will allow you to spawn particles if your ship dies, such as MoO 2's warp core breach, or do any other things that you can think of :)