Tower of Hell random stages | Roblox Forum
Welcome to the Forums!
Join thousands of other Roblox members with a free account.
Create Forum Account

Tower of Hell random stages

  • This website was created by Roblox members to replace the official forums because Roblox shut them down! Join our community if you like to talk about Roblox!

charliemacdmv

Member
Jul 8, 2020
45
7
8
Roblox
Charliemacdmv
Out of curiosity, does anyone know how tower of hell randmomizes the stages? I was thinking of a game using something like that. But I wouldn't even know how to do it.
Post automatically merged:

I know it uses math.random. But im asking how does it load the assets. Like are they all grouped?
 
Last edited:

CallMeKY

Moderator
Ultra
Feb 25, 2018
1,142
274
83
Maine, USA
Roblox
CallMeKY
Discord
CallMeKY#5012
Out of curiosity, does anyone know how tower of hell randmomizes the stages? I was thinking of a game using something like that. But I wouldn't even know how to do it.
Post automatically merged:

I know it uses math.random. But im asking how does it load the assets. Like are they all grouped?

I've never actually played that, but they probably do something like store each thing in a folder in server storage and clone one out of it.
Code:
-- create a folder and a few empty models for the sake of example
local folder = Instance.new('Folder', game:GetService('ServerStorage'))
for i = 1, 10 do
    local newObject = Instance.new('Model', folder)
    newObject.Name = 'Object' .. i
end

-- every second, get one at random and print it's name
while wait(1) do
    local objects = folder:GetChildren()
    print(objects[math.random(1, #objects)].Name)
end
 
General
Help Users
    F Fedruz53: huh