Cleanup
This commit is contained in:
@@ -220,3 +220,4 @@ data ModuleSlot
|
||||
|
||||
makeLenses ''ItemType
|
||||
makeLenses ''ItemBaseType
|
||||
makeLenses ''HeldItemType
|
||||
|
||||
@@ -19,7 +19,9 @@ itemString = head . itemDisplay
|
||||
itemBaseName :: Item -> String
|
||||
itemBaseName it = case _iyBase $ _itType it of
|
||||
CRAFT str -> show str
|
||||
HELD str -> show str
|
||||
HELD hit -> case hit ^? xNum of
|
||||
Just i -> takeWhile (/=' ') (show hit) ++ show i
|
||||
Nothing -> show hit
|
||||
x -> show x
|
||||
|
||||
itemDisplayWithNumber :: String -> Item -> [String]
|
||||
|
||||
@@ -109,6 +109,7 @@ setWristShieldPos itm cr w = w
|
||||
torch :: Item
|
||||
torch = defaultWeapon
|
||||
& itEffect .~ effectOnOffHeld createHeldLight (const $ const id)
|
||||
& itType . iyBase .~ HELD TORCH
|
||||
|
||||
createHeldLight :: Creature -> Int -> World -> World
|
||||
createHeldLight cr i w = w
|
||||
|
||||
Reference in New Issue
Block a user