Constructor - The king of data [GameMaker | Advanced]

Channel:
Subscribers:
11,800
Published on ● Video Link: https://www.youtube.com/watch?v=WpXfj5hpZeI



Category:
Tutorial
Duration: 16:15
2,585 views
149


This advanced video tutorial shows you how to use efficient data with constructors in GameMaker.

Image you have an inventory with hundreds of entries and each entry has values like name, costs, icon image etc. . Creating for each entry one variable per value even with arrays is not an good way to handle that task. So what I think is one efficient way is to create structs via constructor and store each entry into one array. By that you have only one index that defines which item you want values from. That's it!

Tldr: Yes


Video on structs:
https://youtu.be/k874pndLJEs


// slime from the thumbnail:
https://ggoolmool.itch.io/slime


👑 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
📜 Udemy: https://www.udemy.com/course/become-a-video-game-developer-with-gms-23/ (See youtube about page for discount)


----------------------------------------------------------------------------------------
0:00 What we will do
1:22 Subscribe
1:34 Old school way of storing items/data with single variables
2:38 Using arrays to store
3:23 Using structs to store
6:29 Using constructors - Setup
7:00 Store each new entry/struct into an array
8:12 Adding variables to the constructor
10:00 How to grab entries/items
12:58 Modulary advance the constructor with a function







Tags:
game maker tutorial
game maker studio tutorial
gamemaker studio 2 tutorial
game dev
game developer
gamemaker structs
gamemaker structs tutorial
gamemaker data structures
gamemaker oop
gamemaker studio oop tutorial
gamemaker studio structs
gamemaker constructor
gamemaker studio constructor
constructor explained
gamemaker constructor explained