module Dodge.Default.World (defaultWorld) where --import Data.Graph.Inductive.Graph hiding ((&)) import Dodge.ListDisplayParams import qualified Data.Set as S import qualified Data.Map as M import Dodge.Data.World import Geometry.Data import Geometry.Polygon import qualified IntMapHelp as IM import System.Random defaultInput :: Input defaultInput = Input { _clickPos = mempty , _mouseContext = NoMouseContext , _clickWorldPos = mempty , _heldPos = mempty , _heldWorldPos = mempty , _textInput = mempty , _pressedKeys = mempty , _mouseButtons = mempty , _mouseButtonsReleased = mempty , _mousePos = V2 0 0 , _mouseMoving = False , _scrollAmount = 0 , _smoothScrollAmount = 0 , _scrollTestFloat = 1 , _scrollTestInt = 0 , _inputMemory = WasNotMouseGameRotating } defaultWorld :: World defaultWorld = World { _cWorld = defaultCWorld , _wCam = defaultCWCam , _pastWorlds = mempty , _timeFlow = NormalTimeFlow , _input = defaultInput , _toPlaySounds = M.empty , _playingSounds = M.empty , _randGen = mkStdGen 2 , _testFloat = 0 , _testString = "" , _rbState = NoRightButtonState , _hud = defaultHUD , _worldEventFlags = mempty , _crZoning = mempty , _clZoning = mempty , _gasZoning = mempty , _dsZoning = mempty , _wlZoning = mempty -- , _pnZoning = mempty -- , _peZoning = mempty , _incNodeZoning = mempty , _incEdgeZoning = mempty , _gsZoning = mempty --Zoning IM.empty clZoneSize (zonePos _guPos) , _unpauseClock = 0 , _coordinates = mempty , _wSoundFilter = FilterBySoundOrigin $ S.singleton SpawnSound , _tmLDP = terminalLDP } defaultCWGen :: CWGen defaultCWGen = CWGen { _cwgParams = GenParams M.empty , _cwgSeed = 0 , _cwgWorldBounds = defaultBounds , _cwgGameRooms = mempty , _cwgRoomClipping = mempty } defaultCWCam :: Camera defaultCWCam = Camera { _camCenter = V2 0 0 , _camRot = 0 , _camZoom = 1 , _camDefaultZoom = 1 , _camViewFrom = V2 0 0 , _camViewDistance = 1000 , _camItemZoom = 1 , _camBoundBox = square 100 , _camBoundDist = (100, -100, 100, -100) , _camControl = CamInGame{_cigType = CamOnPlayer} } defaultCWorld :: CWorld defaultCWorld = CWorld { _lWorld = defaultLWorld , _cwGen = defaultCWGen , _cClock = 0 -- , _pathGraph = Data.Graph.Inductive.Graph.empty , _cwTiles = mempty , _numberFloorVerxs = 0 , _chasms = mempty , _cliffs = mempty , _numberChasmVerxs = 0 , _incGraph = mempty , _incNode = mempty , _incEdges = mempty , _highlightItems = mempty } defaultLWorld :: LWorld defaultLWorld = LWorld { _magnets = mempty , _oldMagnets = mempty , _modifications = IM.empty , _creatures = IM.empty , _creatureGroups = IM.empty , _clouds = mempty , _beePheremones = mempty , _gasses = mempty , _dusts = mempty , _gusts = IM.empty -- , _itemLocations = IM.empty , _items = mempty , _props = IM.empty , _debris = mempty , _projectiles = IM.empty , _bullets = [] , _plasmaBalls = [] , _flames = [] , _radarSweeps = [] , _sparks = [] , _energyBalls = [] , _radarBlips = [] , _flares = [] , _teslaArcs = [] , _arcNode = mempty , _shockwaves = [] , _lasers = [] , _pulseLasers = mempty , _pulseBalls = mempty , _tractorBeams = mempty , _linearShockwaves = mempty , _walls = IM.empty , _wallDamages = IM.empty , _blocks = IM.empty , _machines = IM.empty , _terminals = IM.empty , _doors = IM.empty , _triggers = IM.empty , _floorItems = mempty , _worldEvents = [] , _delayedEvents = [] , _buttons = IM.empty -- , _corpses = IM.empty , _lightSources = IM.empty , _lights = mempty , _seenLocations = IM.fromList [ (0, (WdYouPos, "CURRENT POSITION")) , (1, (WdP2Const (V2 0 0), "START POSITION")) ] , _selLocation = 0 , _foreShapes = mempty , _distortions = [] , _lClock = 0 , _lTestString = [] , _lTestInt = 0 , _hotkeys = mempty , _imHotkeys = mempty , _lAimPos = 0 , _lInvLock = False , _respawnPos = (V2 20 20, pi / 2) , _tempSPic = mempty } defaultHUD :: HUD defaultHUD = HUD { _subInventory = NoSubInventory , _diSections = mempty , _diSelection = Just (Sel 1 0) , _diInvFilter = mempty , _diCloseFilter = mempty , _closeItems = mempty , _closeButtons = mempty , _manObject = HandsFree , _closeItemsInv = mempty }