forked from sourcebots/sbot_simulator
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Arena.proto
executable file
·136 lines (135 loc) · 3.89 KB
/
Arena.proto
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
#VRML_SIM R2023b utf8
# template language: javascript
PROTO Arena [
field SFVec2f size 1 1
field SFColor wallColour 0.095395215 0.22841774 0.8000001
field MFString floorTexture []
field SFBool locked FALSE
] {
Group {
children [
DEF ARENA_WALLS Group {
children [
Solid { # North Wall
translation 0 %<= -(fields.size.value.y / 2 + 0.075) >% 0.15
children [
DEF NORTH_WALL Shape {
appearance DEF WALL_COLOUR PBRAppearance {
baseColor IS wallColour
roughness 1
metalness 0
}
geometry Box {
size %<= fields.size.value.x >% 0.15 0.3
}
}
]
name "North Wall"
locked IS locked
}
Solid { # East Wall
translation %<= -(fields.size.value.x / 2 + 0.075) >% 0 0.15
children [
DEF EAST_WALL Shape {
appearance USE WALL_COLOUR
geometry Box {
size 0.15 %<= fields.size.value.y + 0.3 >% 0.3
}
}
]
name "East Wall"
locked IS locked
}
Solid { # West Wall
translation %<= fields.size.value.x / 2 + 0.075 >% 0 0.15
children [USE EAST_WALL]
name "West Wall"
locked IS locked
}
Solid { # South Wall
translation 0 %<= fields.size.value.y / 2 + 0.075 >% 0.15
children [USE NORTH_WALL]
name "South Wall"
locked IS locked
}
]
}
DEF ARENA_BOUNDING Group {
children [
Solid { # Floor
translation 0 -0.002 0
rotation 0 0 1 3.1416
children [
DEF FLOOR Shape {
appearance Appearance {
material Material {
ambientIntensity 0
}
texture ImageTexture {
url IS floorTexture
repeatS FALSE
repeatT FALSE
filtering 1
}
}
geometry Plane {
size IS size
}
}
]
name "Floor"
boundingObject Plane {
size IS size
}
locked IS locked
}
Solid { # Ceiling
rotation 1 0 0 3.1419
translation 0 0 2
boundingObject Plane {
size IS size
}
name "Top boundary"
locked IS locked
}
Solid { # North bound
rotation 1 0 0 -1.5708
translation 0 %<= -fields.size.value.y / 2 >% 1
boundingObject Plane {
size %<= fields.size.value.x >% 2
}
name "North boundary"
locked IS locked
}
Solid { # East bound
rotation 0 -1 0 -1.5708
translation %<= -fields.size.value.x / 2 >% 0 1
boundingObject Plane {
size 2 %<= fields.size.value.y >%
}
name "East boundary"
locked IS locked
}
Solid { # South bound
rotation 1 0 0 1.5708
translation 0 %<= fields.size.value.y / 2 >% 1
boundingObject Plane {
size %<= fields.size.value.x >% 2
}
name "South boundary"
locked IS locked
}
Solid { # West bound
rotation 0 -1 0 1.5708
translation %<= fields.size.value.x / 2 >% 0 1
boundingObject Plane {
size 2 %<= fields.size.value.y >%
}
name "West boundary"
locked IS locked
}
]
}
]
}
}