Add menu option to start new game from seed, uses system clipboard
This commit is contained in:
@@ -4,6 +4,7 @@ import Dodge.Data
|
||||
--import Picture
|
||||
--import Shape
|
||||
import ShapePicture
|
||||
import Dodge.Creature.HandPos
|
||||
|
||||
import qualified Data.IntMap.Strict as IM
|
||||
import Control.Lens
|
||||
@@ -44,12 +45,8 @@ pictureWeaponOnAimItem
|
||||
-> Int -- ^ Position of item in inventory
|
||||
-> SPic
|
||||
pictureWeaponOnAimItem p' cr posInInv
|
||||
| isSelected && _posture (_crStance cr) == Aiming && isTwisting
|
||||
= shoulderD twistWep
|
||||
| isSelected && _posture (_crStance cr) == Aiming && isOneHand
|
||||
= shoulderD oneHandWep
|
||||
| isSelected && _posture (_crStance cr) == Aiming && isTwoHandFlat
|
||||
= shoulderD drawnWep
|
||||
| isSelected && _posture (_crStance cr) == Aiming =
|
||||
shoulderD $ translateSPf (aimingWeaponZeroPos cr theIt) 0 p'
|
||||
| isSelected && isTwoHandFlat
|
||||
= handD holsteredTwoFlat
|
||||
| isSelected && isOneHand
|
||||
@@ -61,9 +58,7 @@ pictureWeaponOnAimItem p' cr posInInv
|
||||
shoulderD = translateSPz 18
|
||||
handD = translateSPz 15
|
||||
isSelected = _crInvSel cr == posInInv
|
||||
drawnWep = translateSPf (1.2 * _crRad cr) 0 p
|
||||
twistWep = translateSPf (-5) 0 p
|
||||
oneHandWep = translateSPf 14 0 p
|
||||
holsteredWep = translateSPf (_crRad cr) 0
|
||||
(rotateSP (strideRot cr + 1.2) (translateSPf (-5) 0 twistWep))
|
||||
holsteredTwoFlat = translateSPf (_crRad cr) 0 (rotateSP (twoFlatHRot cr) p)
|
||||
@@ -76,13 +71,13 @@ pictureWeaponOnAimItem p' cr posInInv
|
||||
p = fromMaybe p' $ do
|
||||
x <- theIt ^? itDimension . dimPortage . handlePos
|
||||
return $translateSPf (-x) 0 p'
|
||||
isTwisting = theIt ^? itUseAimStance == Just TwoHandTwist
|
||||
isOneHand = theIt ^? itUseAimStance == Just OneHand
|
||||
isTwoHandFlat = theIt ^? itUseAimStance == Just TwoHandFlat
|
||||
itUseAimStance = itUse . useAim . aimStance
|
||||
f i = 0.1 * fromIntegral (sLen - i) / fromIntegral sLen
|
||||
sLen = _strideLength $ _crStance cr
|
||||
|
||||
|
||||
strideRot :: Creature -> Float
|
||||
strideRot cr = case cr ^? crStance . carriage of
|
||||
Just (Walking x LeftForward) -> f x
|
||||
|
||||
Reference in New Issue
Block a user