• Do not use Discord to host any images you post, these links expire quickly! You can learn how to add images to your posts here.
  • Apologies if you've had troubles connecting to the site, you may need a VPN to access it. Staff are also facing issues connecting, so if it's urgent please message Cat on-site or through Discord directly.
  • Hey Guest, staff applications are open! If you are interested in becoming a forum staff member and/or Discord staff member, please apply through this Google Form before April 2! You can also message Cat with any questions.
Random ID from GameData

Tutorial Random ID from GameData 2022-06-02

TechSkylander1518 submitted a new resource:

Random ID from GameData - Guide to creating a small-scale randomizing mechanic

This is a guide on how to create a method that gets a random ID from game data. (items, Pokemon, etc.) This is most commonly used for events that give the player a random item out of a set, like the tree in the default maps that gives the player a random Apricorn.

Pool
The basic idea here is pretty simple -
  • Create an empty array
  • Add the ID of each entry in the data to the array
  • Sample the array
Ruby:
Expand Collapse Copy
  pool = []...

Read more about this resource...
 
Back
Top