Move towards unifying RoomPos constructors
This commit is contained in:
@@ -73,6 +73,7 @@ posRms bounds parenti@(parent,_) ( (numChild,t@(Node childi _) ):its) tseq = do
|
||||
, _rpPos = fst (lnkPosDir outlnk)
|
||||
, _rpDir = snd (lnkPosDir outlnk)
|
||||
, _rpLinkType = _rlType outlnk
|
||||
, _rpLinkStatus = UsedAsOutLink (_rlType outlnk) numChild (snd childi)
|
||||
}
|
||||
& rmChildren .:~ snd childi
|
||||
shiftedoutlink = shiftLinkBy (_rmShift parent) outlnk
|
||||
@@ -85,6 +86,7 @@ posRms bounds parenti@(parent,_) ( (numChild,t@(Node childi _) ):its) tseq = do
|
||||
, _rpPos = fst (lnkPosDir il)
|
||||
, _rpDir = snd (lnkPosDir il)
|
||||
, _rpLinkType = _rlType il
|
||||
, _rpLinkStatus = UsedAsInLink (_rlType il) 0
|
||||
}
|
||||
shiftedt = applyToRoot
|
||||
(first $ updatechild . shiftRoomShiftToLink (lnkPosDir shiftedoutlink) (lnkPosDir il))
|
||||
@@ -97,6 +99,7 @@ createUnusedLinkPos rm = rm & rmPos .++~ map f (_rmLinks rm)
|
||||
{ _rpPos = _rlPos rl
|
||||
, _rpDir = _rlDir rl
|
||||
, _rpLinkType = _rlType rl
|
||||
, _rpLinkStatus = UnusedAsLink $ _rlType rl
|
||||
}
|
||||
|
||||
zipCount :: [a] -> [(Int,a)]
|
||||
|
||||
Reference in New Issue
Block a user