Move to using RoomLink datatype
This commit is contained in:
+11
-10
@@ -3,6 +3,7 @@
|
||||
module Dodge.Room.Airlock where
|
||||
import Dodge.Placement.Instance
|
||||
import Dodge.Room.Foreground
|
||||
import Dodge.RoomLink
|
||||
import Dodge.Default.Room
|
||||
import Dodge.Default.Wall
|
||||
import Dodge.Data
|
||||
@@ -23,8 +24,8 @@ airlock = takeOne [airlock0,airlock90,airlockCrystal,airlockZ]
|
||||
airlock0 :: Room
|
||||
airlock0 = defaultRoom
|
||||
{ _rmPolys = [ rectNSWE 100 0 0 40 , rectNSWE 65 35 (-40) 20 ]
|
||||
, _rmOutLinks = init lnks
|
||||
, _rmInLinks = [last lnks]
|
||||
, _rmOutLinks = muout lnks
|
||||
, _rmInLinks = muin [last lnks]
|
||||
, _rmPath = [(V2 20 95,V2 20 45) ,(V2 20 45,V2 20 5) ]
|
||||
, _rmPmnts =
|
||||
[pContID (PS (V2 (-35) 50) (negate $ pi/2)) (PutButton $ makeSwitch col red id id)
|
||||
@@ -46,8 +47,8 @@ airlockSimple :: Room
|
||||
airlockSimple = defaultRoom
|
||||
{ _rmPolys =
|
||||
[ rectNSWE 120 0 0 180 ]
|
||||
, _rmOutLinks = init lnks
|
||||
, _rmInLinks = [last lnks]
|
||||
, _rmOutLinks = map (uncurry outLink) $init lnks
|
||||
, _rmInLinks = [uncurry inLink $ last lnks]
|
||||
, _rmPath = concatMap (doublePair. (V2 90 30,) . fst) lnks
|
||||
, _rmPmnts =
|
||||
[pContID (PS (V2 90 115) pi) (PutButton $ makeSwitch col red id id)
|
||||
@@ -70,8 +71,8 @@ airlockZ :: Room
|
||||
airlockZ = defaultRoom
|
||||
{ _rmPolys =
|
||||
[ rectNSWE 120 0 0 180 ]
|
||||
, _rmOutLinks = [(V2 0 30,pi/2)]
|
||||
, _rmInLinks = [(V2 180 30,1.5*pi) ]
|
||||
, _rmOutLinks = muout[(V2 0 30,pi/2)]
|
||||
, _rmInLinks = muin[(V2 180 30,1.5*pi) ]
|
||||
, _rmPath = []
|
||||
-- [(V2 0 40,V2 40 0)
|
||||
-- ,(V2 40 0,V2 0 40)
|
||||
@@ -108,8 +109,8 @@ airlock90 = defaultRoom
|
||||
, (100,10)
|
||||
]
|
||||
]
|
||||
, _rmOutLinks = [(V2 0 40,pi/2)]
|
||||
, _rmInLinks = [(V2 40 0,pi) ]
|
||||
, _rmOutLinks = muout[(V2 0 40,pi/2)]
|
||||
, _rmInLinks = muin[(V2 40 0,pi) ]
|
||||
, _rmPath =
|
||||
[(V2 0 40,V2 40 0)
|
||||
,(V2 40 0,V2 0 40)
|
||||
@@ -141,8 +142,8 @@ airlockCrystal = defaultRoom
|
||||
[ rectNSWE 140 0 0 40
|
||||
, orderPolygon $ map toV2 [ (39,20) , (150,60) , (150,80) , (39,120) ]
|
||||
]
|
||||
, _rmOutLinks = [(V2 20 130,0) ]
|
||||
, _rmInLinks = [(V2 20 0 ,pi) ]
|
||||
, _rmOutLinks = muout[(V2 20 130,0) ]
|
||||
, _rmInLinks = muin[(V2 20 0 ,pi) ]
|
||||
, _rmPath = [ ]
|
||||
, _rmPmnts =
|
||||
[pContID (PS (V2 145 70) (pi/2)) ( PutButton $ makeSwitch col red id id)
|
||||
|
||||
Reference in New Issue
Block a user