mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-02-01 11:49:17 +00:00
added samples for the new tessellations
This commit is contained in:
parent
0acebce55a
commit
65ab10ff18
10
tessellations/sample/inf.tes
Normal file
10
tessellations/sample/inf.tes
Normal file
@ -0,0 +1,10 @@
|
||||
# {3,inf} or another regular tessellation with ideal polygons
|
||||
intslider(sides,3,3,MAX_EDGE)
|
||||
h2.
|
||||
|
||||
let(ia = ideal_angle(sides))
|
||||
let(ie = ideal_edge(sides))
|
||||
tile(0, [ia, ie, ia], *sides)
|
||||
|
||||
conway("(0 0)")
|
||||
#repeat(0, sides)
|
12
tessellations/sample/regular.tes
Normal file
12
tessellations/sample/regular.tes
Normal file
@ -0,0 +1,12 @@
|
||||
## Arbitrary regular tiling
|
||||
## You can change the values of sides and valence. Set sides to max to get infinite sides.
|
||||
intslider(sides,6,3,MAX_EDGE+1)
|
||||
intslider(valence,5,3,MAX_VALENCE)
|
||||
c2(arcmcurv(sides:^valence))
|
||||
|
||||
let(sides1=ifp(sides - MAX_EDGE, inf, sides))
|
||||
|
||||
distunit(arcmedge(sides1:^valence))
|
||||
let(u = regangle(1, sides1))
|
||||
unittile(u,*sides1)
|
||||
conway("(0 0)")
|
28
tessellations/sample/sliders-two-kind.tes
Normal file
28
tessellations/sample/sliders-two-kind.tes
Normal file
@ -0,0 +1,28 @@
|
||||
## triangle alpha-beta-gamma, where alpha+beta+gamma = 360/k degrees
|
||||
##
|
||||
## You can change alpha (=360/k deg * a/3), beta (=360/k deg * b/3), and k using 'tessellation sliders' in the geometry experiments menu.
|
||||
##
|
||||
## Changing k reloads the map, while changing other parameters does not
|
||||
##
|
||||
## Note: the spherical version (k=1) is buggy
|
||||
##
|
||||
intslider(k,2,1,5)
|
||||
c2(2-k)
|
||||
angleunit(deg)
|
||||
|
||||
slider(av,1,0,3)
|
||||
slider(bv,1,0,3)
|
||||
|
||||
let(a = av*120/k)
|
||||
let(b = bv*120/k)
|
||||
let(c = (3-av-bv)*120/k)
|
||||
|
||||
# note the 'if zero' conditional
|
||||
let(ea=test(ifz(k-2, sin(a*deg), edge_angles(a,b,c))))
|
||||
let(eb=test(ifz(k-2, sin(b*deg), edge_angles(b,c,a))))
|
||||
let(ec=test(ifz(k-2, sin(c*deg), edge_angles(c,a,b))))
|
||||
|
||||
tile(ea, b, ec, a, eb, c)
|
||||
conway("(0)(1)(2)")
|
||||
|
||||
cscale(.75)
|
Loading…
Reference in New Issue
Block a user