Game
13 RONIN

7 years ago

13 RONIN - DevLog #2 - Lightning


Ok, It hasn’t been a full month since my first post here, but I still think it’s time for an update, and from now on I plan to post a major news article at the beginning of every month containing a summary of what I’ve been up to lately. For anyone interested in more I recommend my blog at “Eraserhead Studio” where you can find random news, animations, images, sound and code that hopefully can help you out in your own game project.

So, what have I been up to lately?

Well, due to an aching hand, the result of too much asset drawing, I’ve let my hand rest from the tablet and instead focused on doing some proper coding. The result is two quite flexible engines: one for rain and the other one for lightning.

Rain

Since a few of the levels will take place in bad weather it’s important for me to be able to generate some good looking rain. I talked about my rain engine already in the last post but since then I’ve fixed a few bugs, added some properties and posted a higher quality demonstration video on YouTube.

The engine has a lot of settings, all which will help me make a living and varied rain. Some of these are:

  • Drop velocity

  • Drop acceleration

  • Density

  • Drop creation interval

  • Wind

  • No of splashes at ground contact

There are still some minor features to add, such as individual ground height at different z-level, but majority of the engine is now done.

If you want to do something similar for you own project please check out the demonstration video at YouTube:

And why not download the source code from BitBucket.

Lightning

For an even more dramatic effect I want thunder and lightning in the game. I started doing a lightning bolt, then a lightning branch and finally a lightning engine sending randomized bolts and branches through the sky.

5d09edd04a9fc.png

As with the rain engine this engine also has a lot of settings, some of these are:

  • Lightning length

  • Lightning angle

  • Interval between lightning strikes

  • Lightning duration

  • Animation

  • Fade

This was quite fun to code and I’m quite pleased with the result. Things left to add is sound for thunder and maybe a flashing background.

Check out the demonstration video at YouTube:

And get the source code from BitBucket.

A big thank you to Michael Hoffman whose awesome article was a big inspiration in this work. Other inspirations have been google images and YouTube. Just search for “best lightning strike” and enjoy :-)

Shaders

Working with the lightning I spent a few hours and reading up on HLSL and including shaders in MonoGame. It was interesting and fun, but also quite time consuming. There will be a number of shaders included in the end product, but for now it will be a type of coding I will save for the polishing phase.

For anyone getting started with MonoGame and HSLS I highly recommend the article My First Pixel Shader(s).

I’d be very happy for recommendations on other good HSLS pages.

Home page

I’m using WIX for the Eraserhead Studio page but unfortunately the WIX-editor is both slow and buggy. I’ve spent a number of hours in the editor trying to achieve a nicer looking and easier to use site than the previous one but WIX doesn’t make it easy. I’ve still got two active tickets at the WIX-support regarding bugs I can’t find any solutions for, but hopefully the site will still be better than the last one. The short lesson being - don’t use WIX.

Dev forums

5d09edd2d1ed9.png

Besides writing and publishing this post I’ve also drawn avatar, logo and banner and added those to my profiles on:

When I’ve got a finished demo I’ll also get on Facebook and Twitter. Do you have recommendations on other sites where you think I belong? Please let me know.

5d09edd4bef73.gif

Please visit Eraserhead Studio for more.

Happy coding!
/jan.

NOTE. As always, everything I publish here or on any other site is work in progress and subject to change.



0 comments

Loading...

Next up

13 RONIN - DevLog #6 - Time for graphics

13 RONIN - DevLog #4 - Say hello to Ester!

13 RONIN - DevLog #5 - Shouts N' Music

13 RONIN - DevLog #7 - Fight or flight?

13 RONIN - DevLog #1 - Pixel-art samurai fighter

13 RONIN - DevLog #3 - The movie analogy

13 RONIN - DevLog #8 - First public build

Short intro of us 💕✌️

We're an eletro duo based in Seoul 🇰🇷 Heavily influenced by the 90s.

Our new album #Xennials is all about the nostalgia of that era 💽 CD listenin 📟 beeper beepin 💾 floppy disks floppin days 😎

Stream now! 🎧

https://open.spotify.com/album/3YwWhnHWVy5cA8XOpbaGRA?si=8E9awqU…

What do you think guys in my robot?Just a beginner in 3d modeling..

My instagram https://www.instagram.com/rojhonbb/

A Shiny Mega Gengar 🌟 For @ManutkArt 's #ThreeColorsChallenge!