playMaker

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - krmko

Pages: 1 ... 26 27 [28] 29 30 ... 44
406
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:45:40 PM »
Log 10: Endless Wave System Prototype

Finally started on prototyping the endless wave system.



Here's a small update on the wave system, it's growing into a spaghetti monster!



The start wave is the first wave that spawns enemies from a "small wave" pool of enemies, random wave, random squadron (but inside players experience points limit), the it goes to the "check experience points" state, where it check if you're inside threshold for starting the boss wave. If you are, further spawning stops until all the enemies on screen are killed or went offscreen and then the boss wave commences. If you are not, it checks how many enemies are on screen (every enemy that spawns adds a certain value into array which is being checked). So if there's already a lot of enemies on screen you're probably not doing to well and the game will send only a small wave again. If the screen is almost empty, you're bound for a big wave incoming. Also, every wave has it's duration based on type of enemies in it etc.

Anyway, when the boss wave starts. the state checks when it is dead and starts the fancy hyperspace event with animations and creates a random event! Random event can be meteor storm, laser storm, big asteroid field etc. Each one of them grants a bonus during that wave. The next wave starts and so on. Expect even more complicated state machine next time and even more insight :D

407
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:44:58 PM »
Log 9: The Anatomy of An Endless Mode Part 2

I've been on a month+ hiatus due to exhaustion and some personal stuff, but the things are ready to move forward now. I had some issues with the weapon switching system, mostly due to my inept dealing with arrays, but the fresh mind made things alright. As usual, it was just a minor unwanted behaviour (removing the array item which resizes the array instead of rewriting the value on the actual item position) which was hard to spot due to system complexity. Pickup and upgrade system, and together with them, HUD showing the active and inactive weapons as well as heat levels is working good now. Such a joy to see a simple system work, and the knowledge that a massive system is actually behind all of that is priceless.

Anyway, now that the most of the elemental mechanics are done, it's time to make a full time commitment to the actual gameplay.

Let's do a small recap of how things work in an endless mode.

First level:

3 + 0 60 seconds waves with a warp sequence between each of the waves to give player time to rest. At the end of the last wave, you fight the random variation of the first level boss, and warp into level two.

Second level:

3 + 1 60 seconds waves with a warp sequence between each of the waves to give player time to rest. At the end of the last wave, you fight the random variation of the second level boss, and warp into level three and so on.

I will make it quite hard to reach and beat the last boss, and even if you do so, you start all over again, but with bigger score multiplier and tougher enemies.

 
Now let's go a bit in-depth. As i mentioned earlier, 5 spawners are scattered on each side of the screen which makes a total of 20.

During the first wave, only the spawners on the right part of the screen are active and only one at a time can be active. That means that if a spawner spawns a wave of enemies that lasts for five seconds, no other enemies will be spawned during that time. To avoid waiting for the next one to start if you destroy them quickly, the wave also ends when you destroy all the wave enemies and the next one automatically starts.

So, in a way, the better you play, the game is going to throw stuff at you quicker. When it throws the stuff quicker, EXPERIENCE variable, which updates with every destroyed or ended wave, enables the game to do the following:

Activate additional spawners when EXP reaches a certain level
Enable more and more spawners to be active at the same time
Cut off spawning of the waves that are marked to be under EXP threshold (too easy waves)
"Unlock" spawning of the waves when certain EXP threshold is reached
Modify the Bosses' health/attack variable so they also match your skill level

But what about the waves themselves? How are they generated? Well, that's the hardest work of all. There are a couple wave types:

Squadrons separated in a few classes (Big, medium, small). Classes are determined by EXP (higher EXP unlock bigger and harder squadrons). Squadrons are a pain to make, they are a combination of a few enemies in a predetermined pattern (for example, a bomber protected by a few fighters flying in an arrow pattern). There needs to be literally a few hundred of them.

Waypoint enemies. Single enemy types following a certain movement (spline or bezier) and shooting pattern.

Single enemies. Usually very big enemies or few small enemies spawning on a random spawners in a random patterns if there are more than one.

When all of there are combined (along with random events like meteor rain and similar stuff), with randomized spawning locations and spawning based on EXP variable they should all provide an adaptive and enjoyable play experience.

408
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:44:24 PM »
Log 8: Upgrade system and weapon switching part 2

Intro

Turns out that thing aren't always simple as they seem at first glance. I spent more time than planned on overhauling the weapon pickup and replacement system i wrote about in the previous dev log. Apparently, despite the system being laid out well, there were some hurdles that appeared.

First of all, the weapon switching system that was meant to be extremely basic and function by simply activating and deactivating children objects (weapon objects with firing FSMs) on the gunpoint of the ship proved too common for the concept of weapon equipping, upgrading and dropping during the game. I upgraded the system and while it's very complicated and probably can be laid out a lot simpler, it works as intended.

The setup

Upon starting the game, Player is spawned, its child Gunpoint, and Gunpoint children, Basic Weapon Object (Level 1 out of 5 weapon) and Empty Weapon Object. You're probably wondering why would i put something like Empty Weapon when it's not even used, but we'll get to it. Every Weapon Object has two FSMs, Main FSM, used for the upgrade system, and Firing FSM, used for firing the weapon. Gunpoint object stores the Weapon Switch FSM. Bear in mind that Weapon Object can also be Weapon On Ship, or a Weapon Pickup, depending on the state in which it is and the fact that Player can have two weapons equipped, but only one active at the same time.

Weapon Upgrade System - how it works?


Main FSM controller on the Basic Weapon Object enters the first state. It searches for the Gunpoint object (place on the ship where it will be spawned. Search is done by tag, since it is quicker than searching for it by name). When it finds it, it stores it in the variable. By checking if the Weapon Object is childed to a Gunpoint or not, the Main FSM is branching in two directions, which determines if it's really a weapon equipped by Player, or a Pickup waiting to be collected.

Shorter branch is executed is if the Weapon Object is a child of the Gunpoint object. It is then stored in the Weapons On Ship array, and the Main FSM finishes it's job for now. That means that it is a weapon equipped by Player and it can be fired.

If it is not childed, it means it's a Pickup (drifting in space, waiting to be collected), its Firing FSM is disabled, a child which is an animated circle indicator for easier visibility is activated and the state machine starts its next event.

Weapon Object starts measuring distance from the Player. When the distance drops below defined value, Weapon Object can receive the key command from the Player, otherwise, it's non-responsive to key press. In game terms, when the Player hovers over the weapon, by pressing key following states can occur:

Simplest case occurs if the same weapon type of maximum upgrade level exists on the ship (checked by iterating through the Weapons On Ship array). "Weapon is at maximum upgrade level" message appears, the pickup eventually leaves the screen and it is despawned.

If the same weapon type of lower upgrade levels exist on the ship, it is upgraded. If the pickup is of the same or lower level than the weapon on the ship, the weapon on the ship is upgraded by one level. But if the pickup is one or more levels higher than the weapon on ship, the weapon on the ship is upgraded to that level. So, you get a pickup and it upgrades your weapon by one or more levels and it disappears. In game terms, it sounds simple, but actually there's a lot of mechanics behind it.

For example, Player is equiped with Level 1 Weapon, and there's a Level 1 Weapon Pickup which we collect. Level 1 Weapon Pickup iterates through the Weapons On Ship array, and it finds the Level 1 Weapon of the same type. It gets the position of the Gunpoint object, spawns Level 2 Weapon and adds it to the Weapons On Ship array. It also checks if the Level 1 Weapon in the array has its Main FSM enabled or not. If it is enabled, that means it's an active weapon (we'll also get to it when we get to the Weapon Switching mechanism), which means that the Level 2 Weapon that is spawned should also be active which is done by activating Firing FSM on Level 2 Weapon nad adding it to the Active Weapon array (needed for the Weapon Switching mechanism). Firing FSM on Level 1 Weapon is disabled, it is removed from the Active Weapon array, removed from the Weapons On Ship array, Level 1 Weapon equipped on ship itself is despawned and Level 1 Pickup is finally despawned at the end of the last state. If the Level 1 Weapon on ship is inactive (its Firing FSM is deactivated), the Level 2 Weapon also spawns with its Firing FSM deactivated, but is not added to the Active Weapon array.

What happens if the Player is equipped with one or two weapons that are different from the pickup?

Things get a bit complicated there. If Weapon On Ship array does not contain any of the levels of the Weapon Object that is the same as the Weapon Object pickup, a Replace Active/Replace Empty state is entered. Remember the Empty Weapon object from the setup? It is used as a placeholder when picking up a weapon that is different from the basic equipped weapon. By iterating the Weapon On Ship array and finding no weapons of the same type but finding an Empty Weapon object, it is simply despawned, removed from Weapons On Ship array and replaced by the picked up Weapon Object. Since it is not active, spawned weapon Firing FSM is also not active, thus not added to the Active Weapon array.

A different Active Weapon acts similar to an Empty Weapon object if all slots are taken. It is removed from the Weapons On Ship array, removed from the Active Weapon array, deparented from the Gunpoint, its children activated (circle indicator that makes it visible more better on screen), and the pickup is spawned on the Gunpoint. As i said in the beginning, whenever a Weapon Object spawns, it immediately checks if it is a parent of the Gunpoint or not, and then added to the Weapons On Ship array or not.

Switching Weapons

Finally, switching the weapons. First we need to make sure that the Player can't cycle between the equipped weapon and the Empty Weapon object. As long as the Empty Weapon is in the Weapons On Ship array, cycling is not enabled. When it is no longer contained in the array, Player can freely switch between weapons. Every switch gets the first and second index numbers of the Weapons On Ship array, stores them as Weapon 1 and Weapon 2 variables, enables and disables Firing FSM on them, adds the Weapon Object with enabled Firing FSM to the Active Weapon array, and removes the Weapon Object with disabled Firing FSM from the Active Weapon array. We need the information about the Active Weapon so it can be replaced with the pickup that is different from it. That enables the Player to upgrade the weapon of the same type as the pickup on ship whether it is active or not, or select which weapon will be replaced (if both are different from the pickup) by simply switching weapons to active or not.

Oh, by the way, you can visit www.fatpugstudio.com for version with bolded arrays, objects and things of interest, it didn't copy it nice.


409
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:43:44 PM »
Log 7: Upgrade system, weapon switching, and a word on visual scripting

It's been almost two weeks and i've been very busy with my day job so i didn't manage to spare too much time for game, but i finally finished (for me) a very complicated thing - upgrade and weapon switching system.

Player starts out with one weapon. During the game he can pickup a variety of weapons from destroyed cargo ships. The first time he picks up a weapon, it is added as a second weapon, and player can switch between them according to situation (bullet, energy and missile weapons don't deal the same amount to normal, armored and shielded enemies). When another weapon appears as a pickup, two scenarios are possible: if the weapon is already equipped, it gets upgraded and the pickup despawns. If the weapon is already at maximum upgrade level, player is notified via on-screen message and the pickup stays where it is. If the weapon is not equipped, currently selected weapon is replaced (dropped as a pickup, while pickup spawns on player). While dropping the weapon is not very important in single player game and complicates the situation a lot, it is handy in 2 player game, where one player can drop a weapon for the other player to upgrade his weapon. The handy thing is that when a player drops, for example, Hyperblaster Level 4 and the other player picks it up, he'll get the Level 4 Hyperblaster too, not level 1. Since there are (for now) 23 weapons in game and the only way to upgrade them (besides universal weapon upgrade pickups) is to pickup the same weapon, that will be very cool in terms of player cooperation.

Here's a shot of an FSM




Basically, when the weapon spawns, it checks itself if it is a weapon or a pickup (by checking if it is parented or not). If it is a weapon, that means that it is player equipped and it is added to the array and the variable is stored if it is in slot one or slot two (required for weapon switching during the game). If it is a pickup, distance check state is activated. Player can only pick it up if he is closer than a defined distance from it (by pressing space, so no accidental pickups are possible). When he picks it up, it iterates through the array to see if it will replace the existing weapon (if no weapon of same type is found) or upgrade it (if weapon of same type is found). If it replaces it, the existing weapon is dropped (which means it is despawned, removed from array, spawned on location of a pickup with its firing scripts disabled and pickup indicator enabled, while next level weapon is spawned on gunpoint with its firing scripts enabled and pickup indicator disabled).

Weapon switching is, compare to the upgrade and pickup system, a walk in the park. Stored weapons are simply activated/deactivated by pressing the switch key.

Scripting this thing alone would probably take a lot more time than it did, so using Playmaker did the job pretty quick since i can try something out in a matter of seconds, not waiting to write a couple of lines with risk of making syntax errors.

But, here comes the downside. Instead of making the script that can just be copied/pasted on all weapons (have in mind that there are 23 weapon with 3-5 levels each, so that comes to about a hundred prefabs, with more to come), i have to copy/paste an FSM to every weapon and tweak the variables in each one of them. I don't have to tell you that if any larger scale fixes in logic are necessary when all the weapons are already prepared it will be a lot of work to change everything. Not to mention the possibility of making errors when managing such a tedious task.

One more thing i did is implementing the sprite atlas which reduced draw calls a lot, and boosted frame rate from 15-30 FPS to ~150. Now everything goes very smoothly. There are some hiccups, but those are due to extensive logging which is quite necessary in this phase. I also redid swarm missile logic, now they are very cool and fly in a great semi-random manner.



Also, the artist guy did some weapons art for me, some will maybe change, but i thing they're pretty good looking and quite different.



That's all for now, cheers!

410
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:41:43 PM »
Log 7: Swarm Missiles

I don't know how smart is to waste 4 days on a small feature such as one of many weapons in the game (especially with only few months remaining), but i just can't do things half-assed.

Here's the old one, which wasn't quite satisfying. The rockets seem to go in a predefined pattern, not randomly.



Here's the new one, so much better. Sorry for the framerate, i'm still not using sprite atlas so there's a lot of draw calls. That will have to be the next thing to address.


411
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:41:17 PM »
Log 6: Small Recap

Well, i think it's about time to (after a year of learning and developing) tip the percentage of game completed to 20%  ;D

Anyway, my last devlog was 4 days ago, and i started tracking things more seriously.

Small tasks are in Wunderlist, so they can be quickly added and quickly disposed of in any time and anywhere. It's also quite convenient for jotting down a quick idea.

I use Trello for communication on ideas with the artist and keep all the stuff there for a sense of visual direction.

Since Unity implemented the cloud collab stuff, i can also write down stuff i did and see it in collab history.

There has been quite a few problems, but also a few acomplishments in the last few days, it's actually pretty great to go through the list and see all the things you have done, keeps you motivated.

So here's the list for the past 4 days:

Design of the swarm missiles weapon, though it may require an overhaul to make them more random with some sort of unnecessary crazy loops to compensate for their number.

Design of the Randomizer (work title) weapon which shoots a lot of particles but to compensate for their number they move in a random forward pattern.

Design of the shield with regeneration timer and connection to the shield integrity bar. Still needs connecting to the heat transfer mechanism (when you get hit, shield takes the damage, but your heat level increases).

Design of the Auto Cannon Drone. It tracks closest enemy, rotates towards it and fires. If on enemies are present, it stops firing.

Design of the Ripper, basically a manual shooting shotgun, that was pretty easy. It shoots as fast as you can click, but it heats a lot.

Design of the Flak Cannon. Like the real Flak, it has proximity activated "fuse". At the certain distance from the enemy it explodes and blasts into a lot of small pellets.

Design of the Proximity Mines. We got regular mines just floating in space, but i decided to put a bit more challenging ones. When you get near one, it starts slowly moving towards you until you destroy it. I also designed the EMP mines that will work the same way, but deal less damage and f*** up your screen with glitch effects. Also updated the mines with random rotation and blinking red light so they're a bit more interesting looking and easier to spot.



Artist started working on explosion for destroyed enemies, explosions for bullets, and bullets themselves. There's already a lot of ships that require a lot of time for movement and shooting patterns, so we put the design of the next round of ships on hold until the existing ones are finished.

Tons of bug fixes, as usual.

I'd post a gif as usual, but everything's done with placeholder graphics, so i'll post something juicy next time.

412
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:40:48 PM »
Log 5: Enemies

Paragons: 8 ships
Pirates: 12 ships
SunDyne: 5 ships
Terran: 4 ships
Rift Miners: 7 ships
Rokh Raiders: 0 ships

Total: 36 ship + asteroids, pickup boxes etc. The plan is to make about 10 ships for each faction, so that totals to about 60 ships, which is more than enough to keep the endless mode interesting for a long time.

The plan is to make about 10 ships for each faction, though it's a lot of work to make each ship unique in design and attack formations and weapons. So i started modyfing some of them. For example, the Pirate Marine Carrier has normal and elite variant, the other one is tougher, and spits out elite marines.

Regular Pirate Marine Carrier


Regular Pirate Marine


Elite Pirate Marine Carrier


Elite Pirate Marine


So these days are all about designing enemies in a sense of their HP, attack power, bullet patterns etc. After the design of all enemies is complete, i'll start putting them in waves and further tweaking power and the threshold of their appearance. The good thing is that the big part of graphical assets is complete, so the expenses are coming down, so i might even finish the game in under 3k euros.

To keep things interesting, here's a little gif of player being shot by EMP weapon. Doesn't do much damage, but you're pretty much screwed if screen is already full of bullets. Probably gonna tweak it a bit.



413
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:40:15 PM »
Log 4: The Anatomy Of An Endless Mode

Some time before new year i realized that the volume of work required to make both story and endless mode for the game is too much for me to finish in the amount of time i have given myself. Besides work, i have a small child, and the only hours left for work are after the little one goes to bed, which can be exhausting in the long run. I made a slight reorder of priorities - finish the endless mode first, give people something to play, put it up as an early access title, then work on the story mode.

Besides having to finish all the graphics, audio, and mechanics stuff completely much before planned, the challenge of making the endless mode itself presented. Of course, for it to be interesting, it has to be semi-procedural. How is it done?

Rough Construction

First level:

3 + 0 60 seconds waves with a warp sequence between each of the waves to give player time to rest. At the end of the last wave, you fight the random variation of the first level boss, and warp into level two.

Second level:

3 + 1 60 seconds waves with a warp sequence between each of the waves to give player time to rest. At the end of the last wave, you fight the random variation of the second level boss, and warp into level two.

You get the idea how it goes further. When all the levels are completed, you start from level one but on a much tougher scale. What does that mean? Points, enemy movement, enemy shooting speed, enemy bullet damage, enemy health variables and so on, they are all multiplied. As it name says, it's endless, and the goal is to get as much points as possible.

Wave design

This one was a bit harder to implement. Around the screen, 20 spawn points are arranged (five for each side of the screen).



Prefab pool for each type of enemy is made and squadron combinations of all enemies were made. Each is assigned a progression level, which is basically a threshold for appearing (or not appearing). The variable enables the algorithm to avoid spawning too many or too tough enemies on first levels, and too few and too weak enemies when you're already on the higher levels. Separation into prefab pools and squadron combination allows us to have a variety in spawning a combination of hand made patterns and waves of many randomly scattered enemies of one or more types.

I must admit that Unity maybe wasn't the smartest solution for this type of game. It has lot of possibilities, but every one of them must be carefully tweaked and automated for the system to work as intended. For example, i don't want to make duplicates of all the enemy squadron combinations for every movement direction, so i had to make a script that automatically flips the sprite, shooting direction and movement direction according to the position where the enemy wave spawned (if it spawned in one of the spawners on the left side of the screen, its sprite is automatically flipped on the X axis and it's movement is set to right). For enemies moving along the waypoints, this is omitted and they automatically align themselves according to the waypoint direction. Waypoints allow us to make interesting waves rather than using only linear moving enemies.

Here's one of the early waypoint making images:



So, to make things interesting, we have a combination of hand made enemy patterns, procedurally generated enemy waves of one or more enemy types, randomly (but with a distributed chance) selected spawn locations or waypoint movement patterns and different boss variations. To make things even more interesting, there's a slight chance of events (asteroid field throughout the entire level and such things). Only things predetermined are level bosses (though they are also varied by their types which are basically shooting and movement patterns), and ships carrying power-up which MUST appear every wave for the player to progress. They drop a random weapon/equipment/power-up, which can be changed by shooting it.

The progression level also determines a perk selection screen activation where (similar to crimsonland) you can choose to cooldown your weapons faster, have more damage on energy or bullet based weapons, get a score multiplier etc.

Backgrounds randomly change after each wave (warp) so that's not boring too. They are chosen from the array and removed from the array once they appear. When the array is emptied, it fills again, and background change randomly again. Same thing goes for music.

There it is in a nutshell. It needs a lot more work on testing and balancing, but i hope you will get to play an alpha of an endless mode in a month or two :)

To keep you interested, here's a pic of another faction, the Paragons, which utilize cloaking and phase shifting (basically disappearing and appearing on random coordinates of the screen).


414
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:39:40 PM »
Log 3: Introducing the Rift Miners

I've been really busy with my job, as usual on year's end, but my graphics guy has been working, so i've got a little teaser for faction #2, The Rift Miners, race of sentient mining robots. It is for the social network, so i'm not going to spam it into a new posts here, i'll just edit the existing one just to show you the process. Idea is to make people a bit interested by showing shapes fist, then identifying one ship per day. Here's all revealed



Also, i started working on the Endless Mode mechanics as i decided to give people something to play before i finish the Story mode. It's not complicated, it's based on levels consisting of randomly generated waves (but in a smart way!) with the boss enemy as the last wave. Weapons and equipment will be dropable, and you get to choose perks as you gain experience.

415
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:39:05 PM »
Log 2.1: Flamethrower complete!

I must admit that this was not an easy task, but i finally did it, a functional spray weapon that deals damage to the enemies.

First step was to make the animation out of the frames i provided with the sprite sheet you can see in the tutorial i posted. Animation settings in Unity are very powerful, and you can put every aspect of the thing you animate on the curve. I've put the X and Y Scale on a slight upward curve so the animation starts small, and gets bigger (like the thing i did with the Particle System in the previous try). Once i was satisfied with that i created the weapon template using Uni Bullet Hell asset. I used the Random Shot preset which has tweaks available for the Random Range Size (which is the angle in which the shots will be fired randomly, like the cone. I've set it to 15 degrees for start). Auto Release Time, or after how much time will the bullet get back to Spawning Pool (instantiation and destruction takes much resources) is set exactly to the animation length so it doesn't repeat itself. Speed of the bullet is randomized between 1.1 and 1.5 values to get a more natural, random look. The initial Random Range Size property was fed into an FSM which randomizes it between 10 and 30 range to get even more natural/random flame look (talk about natural flame in space ::)) and the Z axis of the sprite is also randomized so that every bullet slightly rotates a different way during its pitiful one second existence.

With all that finished, it was time to do the routine work, adding some usual stuff to the bullet. 2D Collider and 2D Rigid Body for hit detection, the Killable component of the Core Gamekit which is used to apply Attack Points which will be dealt to enemies upon collision (the enemies in the gif have 200 HP, so i've set it to 1, since there's a lot of small bullets. The starting weapon, a regular one bullet blaster has 100 Attack Points for example, so it takes out those little baddies in two shots), and setting the bullet to die at any collision.

Here's the result (wait a bit, it's a big gif), i may tweak the reach of the weapon a bit, or mess with the sprite sheet to give it a fuller and more colorful look, but that about does it! All there's left to do is connect it to the Heat Meter so you can't fire it indefinitely since you'll overheat, but that's the story for another log.



Hope you enjoyed, cheers!

416
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:38:35 PM »
Log 2: Troubles with the Flamethrower and making a font

Well, the flamethrower looks really nice, but in reality it proved quite useless. Apparently, particles, despite having their own type of colliders, don't have rigid body and collider in the sense of the regular components. They do collide and react with other colliders, but any other interaction with them must be done via OnParticleCollision behaviour, which is currently not supported the way it should be in Playmaker or Core Gamekit which i'm using, so i will probably have to do it the old fashioned way - in code.

But i have another interesting idea that i'm yet to try...i'll keep you updated  :handanykey:

Edit: i forgot, i also made a custom font for the game, since i don't like any i found on the internet. I took me about 20 minutes. 3 pixels is too small, 7 is too big, 5 pixels was just about right for size and scaling. You can make your own fonts on www.fonstruct.com, a very handy website.

Here's how it looks like:


417
Work In Progress... / Re: Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:38:15 PM »
Log 1: Making a Flamethrower

Today i decided to finally bring an end to an agony i had with designing the flamethrower.

What are its characteristics?

- It fires a lot of small particles which increase in size over time
- The particles are emitted in cone shape
- The particles should be animated over time

I tried a bit unusual approach first time. I made a regular weapon which shoots bullets (in this case, small round sprites) by using UniBullet Hell which i use for most of my guns.

A simple setting using a tweaked random preset:



The trick should be done by getting the bullets scale and collider size, saving them in a float variable, and then adjusting that variable over time. To avoid the bullets growing too big, i clamped the float value to a maximum value and put a death timer for the bullets to disappear after a certain amount of time, thus making a weapons range. Unfortunately, unexpected behavior appeared which i was unable to solve. After a while, the bullet instantiated size started growing more and more, and after a few seconds i would end up with particles which are all the same size (the float clamp size).

I scrapped the thing, and today i tried making it using Unity's particle system.

Step 1:

Making a sprite sheet of particles that would appear. It consists of 12 sprites in one row, 9 being some colorful orange and yellow blobs, and the last two diminishing blobs to mark the end of the flame spray.

Step 2:

Making the material for the particle system. It's not all easy-peasy with particles in unity. To apply spritesheet to the particles, you have to make the material out of it first. Just make sure to select the particles for shader. Some nice blending options can be chosen here too, but we'll stick to good ol' Alpha Blend.

Step 3:

Creating the particle system itself.

Shape - Needs to be set to cone since we are simulating, well, a fire cone.

Size over lifetime - Not to small at the start, since it will be practically invisible, but all the way to value of 1 at the end.

Collision - We want our fiery particles of death to collide with enemies, so we set the collision mode to world and 2D. You can also choose the layers which will be collided. Since my enemies are on their own layer, we choose that layer.

Texture Sheet Animation - This is what we made the sprite sheet for. Just enter the number of tiles for X and Y (in my case, X - 12, Y - 1, which means 12 sprites in one row). We're not touching frame over time options, which means the sprites from the sheet will be generated in order in which they are drawn.

Renderer - Here we will just put the lovely material we made from the sprite sheet we made earlier, nothing else needs to be touched.

Step 4:

All there's left to do is to tweak some of the basic settings like duration, start lifetime, speed, size, max particles, emission rate etc., which basically let's us control how long will the flame cone be, how fast will it shoot and according to that, how much damage will it make.

The thing that must not be forgotten is that the particles must have independent movement when you move the ship, so the simulation space must be set to world.

Here's the finished work



I just made a complete tutorial for making a 2D flamethrower in Unity, you can check it out on the frontpage of my website, www.fatpugstudio.com :)

418
Work In Progress... / Rick Henderson And The Artifact Of Gods
« on: July 03, 2017, 11:37:39 PM »
Hi guys, since i'm a regular poster here i thought i'd share my devlog with you too!

First of all i would like to introduce myself. I come from Belgrade, Serbia, i'm 34 and i grew up playing likes of U.N. Squadron, R-Type and Uridium on C64, then Z-Type, Project X and Xenon 2 on Amiga 500, all the way to Jets 'n' Guns and Steredenn on PC. I have been stalking the forum for a long time, but opened an account just recently, and i decided to open a DevLog thread where i could share the news on the game's development, make someone interested, and above all, help someone by sharing my experience in game development (which proved to be a very serious thing  Smiley).

Gameplay and features

RHAG is, despite it's name fitting an adventure game better, a more or less classic 2D horizontal scrolling shoot 'em up i always wanted to make. It's a mixture of Jets 'n' Guns (who has the Story Mode) and Steredenn (which is basically and Endless Mode only game). The story features Rick Henderson, a disillusioned galaxy war veteran who turned to suspicious activities after the war to make ends meet, his robot follower, sarcastic Ben who makes every conversation fun, and a lot of NPC's who will be introduced during the development.

Story Mode Single Player - Interesting storyline full of dialogues with interesting characters to keep you amused between levels.
Endless mode with Multiplayer - Local and Online
Daily Challenge - Once per day Endless Mode Run with predefined equipment and perks
Online Leaderboard - Compare your scores with your friends and other players
6 factions - Pirates, Rokh Raiders, Terran Confederacy, Vakshaa, SunDyne Corporation and Paragons.
40+ types of enemies (for now)
30+ types of weapons and upgrades (for now)

Single Player is featuring a shop between levels where you can equip your ship with weapons, drones, engines, utilities, shields and armors.

Weapon types: Ballistic, Energy, Explosive, Meelee. Each type of enemy is usually resistant (partially or fully) to a certain type of damage, so watch your loadout! Ship can equip two weapons, but they can't be fired simultaneously. Weapons also generate heat, so you can't keep that button pressed all the time.

Graphics:

Game is done in pixel art which i really love and which proved itself as (usually) the best choice for shmups due to its clarity (and yes, development costs). I'm not much of an artist, so besides the things i do myself (backgrounds and small art), credits go to Lighterthief, a young lad from Netherlands who does some amazing graphics. I'm often awed how quickly he can make some good looking stuff. You can check his art on his Twitter account: @Lighterthief

Sound:

I've been a musician and sound designer in my spare time doing mostly electronic music for the last 15 years, so i've got that covered.

More Information

Website - http://www.fatpugstudio.com
Twitter - https://twitter.com/FatPugStudio
Tumblr - http://rickhenderson-game.tumblr.com

419
Playmaker Help / Re: 2 questions regarding facing direction in 2D
« on: July 01, 2017, 01:23:51 PM »
"Get Position" on both the Ship and the Target. Storing them as Vector3

Subtract the Ship Vector from Target Vector using "Vector3 Operator" storing it as a new variable.
Now do a large multiplication to your new variable (To ensure the target position will move off screen) using "Vector 3 Operator".

Finally, "Vector 3 Add" your New Vector to your Target Vector and start your movement commands on your ship ("Move To" should work fine).

What we're doing is moving the target further away before movement even takes place. These calculations just make sure that your ship will path through the intended point on the way to it's new target position.

It's not a pretty solution, and it has limitations but it should accomplish what you're after. I'd recommend looking at the Physics actions for a more sophisticated solution, but i don't have much experience with that yet.

Just wanted to let you know it works perfectly, thanks again!  ;D

420
Playmaker Help / Re: Compare variable range
« on: June 29, 2017, 03:28:48 AM »
Awesome man ;D

Pages: 1 ... 26 27 [28] 29 30 ... 44