![Real time 2D lighting - [Game Maker Studio 2 | Basics]](/images/yt/0d/real-time-2d-lighting-game-maker-studio-2-basics-v4exo.jpg)
Real time 2D lighting - [Game Maker Studio 2 | Basics]
This basics video tutorial shows you how a real time 2d lighting can be done in GameMaker Studio.
Basically what you see in this video is that you have one object that checks if there is a obsticle in the way in form of tiles. That is being stored in the buffer to create a primitve. This is in the end only tons of little triangles in a list that fill up the screen to indicate that the origin can't see there.
A disclaimer: This si quite demanding for your game, so only use it sparingly when you really need it. I have seen and tested a version that checked for wall objects instead of tiles, This one was even worse in performance.
The whole project is based on those 2 yoyo offical blog posts, so if you like to see the full documention, here are the links:
https://www.yoyogames.com/blog/419/realtime-2d-lighting-in-gamemaker-studio-2-part-1
https://www.yoyogames.com/blog/420/realtime-2d-lighting-in-gamemaker-studio-2-part-2
// light system:
https://youtu.be/7GFggYDglmo
โถ Gamemaker Studio: https://www.yoyogames.com/get
โถ Trial limitations: https://help.yoyogames.com/hc/en-us/articles/230407528-GameMaker-Studio-2-Trial-Limitations
๐ฎ My free game Clunky souls:
https://1up-indie2.itch.io/clunky-souls
๐ My assets:
Get some assets at itch.io https://1up-indie2.itch.io/
๐ Udemy: https://www.udemy.com/course/become-a-video-game-developer-with-gms-23/?referralCode=6AB816C3B321FB60C885
๐ Support me and get fresh game art and game maker projects every month:
https://www.patreon.com/1upindie
Follow me on:
๐ธ Instangram: https://www.instagram.com/1upindie
๐ฆ Twitter: https://twitter.com/1upIndie
๐ฌ Discord: https://discord.gg/gvr98nb