Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // çèìà
- ds_grid_set_region(ds_dungeon, 0, 0, room_width / 32, room_height / 32, 0)
- biome[2, 1] = irandom(room_width div 32)
- biome[2, 2] = irandom(room_height div 32)
- biome[2, 3] = irandom_range(3, 16)
- biome[2, 4] = irandom_range(3, 16)
- ds_grid_set_region(ds_dungeon, biome[2, 1], biome[2, 2], biome[2, 1] + biome[2, 3], biome[2, 2] + biome[2, 4], 1)
- for(i = biome[2, 1]; i < biome[2, 1] + biome[2, 3]; i += 1)
- {
- for(j = biome[2, 2]; j < biome[2, 2] + biome[2, 4]; j += 1)
- {
- chance[1] = choose(-1, 1)
- chance[2] = irandom(10)
- chance[3] = choose(-1, 1)
- if chance[1]
- {
- if chance[2] == 10
- {
- if chance[3]
- {
- r = irandom(2)
- ds_grid_set_region(ds_dungeon, i - r, j - r, i + r, j + r, 0)
- }
- }
- }
- }
- }
- for(i = biome[2, 1]; i < biome[2, 1] + biome[2, 3]; i += 1)
- {
- for(j = biome[2, 2]; j < biome[2, 2] + biome[2, 4]; j += 1)
- {
- if ds_grid_get(ds_dungeon, i, j)
- {
- o = instance_create(i, j, block)
- o.type = 2
- }
- }
- }
Add Comment
Please, Sign In to add comment