This repository has been archived by the owner on Jun 19, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gen2-zebra.py
55 lines (43 loc) · 1.75 KB
/
gen2-zebra.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
"""
Smash Hit Room Generator v2
Codename Zebra
This generator is based on a lite-weight, non-conditional set of rules about
where objects should be placed. Prefab-like elements start as being placed in
spots in the level where they are allowed to be, then they are actually built.
List of possible rules for mid segments:
1. All segments must contain one obstacle and/or one or two crystal obstacles.
a. If the segment contains obstacles, they must be within CollisionAccuracy
radius of the player's centre point (which is always [0.0 1.0 -z]).
b. If a segment contains crystals, they must be within the LevelLimits.
c. If a segment contains crystals AND it contains an obstacle, then the
crystals shall not appear in the CollisionAccuracy radius.
2. All segments must have zero or more stone walls outside LevelLimits.
a. If a segment has walls, they must be well aligned to the boundaries and
may be decorated like walls in Smash Hit.
3. All segment must have decorative stone and possibily decals outside of the
CollisionAccuracy radius from the player centre.
a. If a segment contains more than one decoration, then it must not
intersect another decoration.
b. For any decoration, it should be true that it does not intersect with
any other entities.
I. Decorations shall be created only in empty space to avoid violation of
rules 3a and 3b.
"""
from smashhitbuilder import *
import random
import typing
class Top: pass
class Bottom: pass
class Left: pass
class Right: pass
class LevelStructure:
"""
A collection of variables controling the structure and properties of a
level.
"""
def __init__(self):
pass
def main():
pass
if (__name__ == "__main__"):
main()