You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Optimizations in world drawing only visable fog of war tiles are drawn
Optimizations in world drawing the fog of war is recalculated every second instead of every frame
Optimizations in world drawing fixed redrawing of overdrawn actors, buildings or objects by building could cause them to be revealed in fog of war
Optimized miniMap drawing routines.
Minimap fog of war is updated in 16 sectors
Terrain is only drawn once instead of every refresh
Objects are only redrawn on change
Actors are still always updated
Fog of war sector iterator name changed
Reduced fog of war update time to a complete update every 3 seconds
Reworked the spawnFoodStoneGold function
The placement should be more scathered around the map now (it will try to place on a random grid instead of going from left to right for every row. By having grids instead of just a random map tile it will ensure it is not placing two resource groups of the same resource close together.
Redone findRandomFoodSource
now checks if a source of food is occupied by another player
claims an unoccupied food source
lumps food sources close together as food groups
only retains one food source per food group to prevent players spawning on the same food group
check to prevent an infinite loop when the are not enough food sources for all players
Templates
(for easy future addition of actors, objects and buildings) Actor templates Object templates Building templates
Implementation of actor templates for easy addition of new actors
Implementation of different movement speeds for actors
fixed building texture error being hardcoded
getBuildingSprite() now returns a reference
marked getBuildingTexture for removal
removed redundant setter functions
Barrack texture would corrupt because it was set to animate, while the sprite did not have animation
Furter changes
Const correctness thourgout the project
Alphabetical ordering of declarations of functions and variables in classes
Removing duplicate functions, and moving functions to globalfunctions.cpp/h
All coordinates are now stored and transferd between functions in cords struct
Made const variables for calculations that were done hunderds of times while the imput was constant
Checked rounding of percentaged based calculations before casting them to an integer
map elements now use std::array instead of c-style array
Messages now disapear after half a minute instead of a minute
Actually show a loading screen
Added granulair controll over the amount of food, gold and stone on the map
correct type casting
Removed unused int's in drawToolbar
made all enums scoped
moved bigSpirteYOffset to templates
Fixed: actor chase function broken after cords refactoring
Fixed: villager order buttons where generated as many times as there where villagers selected
Fixed: Actor selector buttons where drawn in the same place. Now a grid is made so induvidual actors can be selected
Fixed: redrawing of overdrawn actors, buildings or objects by building ould cause them to be revealed in fog of war
Fixed: find alternative resource could call front on an empty and even depricated list.
Fixed: immortal actor: A walking actor could stay visable on the map and become immortal because the actor was occupiing two tiles. Only the tile stored in actorLocation would get cleared
The above changes removed stuttering framerate (noticable when scrolling the map) and made the debug build actually playable since a long time) Suggestions for furter optimization (if needed in the future)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
World drawing opimazations
Reworked the spawnFoodStoneGold function
Redone findRandomFoodSource
Templates
(for easy future addition of actors, objects and buildings)
Actor templates
Object templates
Building templates
Furter changes
Fixed: actor chase function broken after cords refactoring
Fixed: villager order buttons where generated as many times as there where villagers selected
Fixed: Actor selector buttons where drawn in the same place. Now a grid is made so induvidual actors can be selected
Fixed: redrawing of overdrawn actors, buildings or objects by building ould cause them to be revealed in fog of war
Fixed: find alternative resource could call front on an empty and even depricated list.
Fixed: immortal actor: A walking actor could stay visable on the map and become immortal because the actor was occupiing two tiles. Only the tile stored in actorLocation would get cleared
The above changes removed stuttering framerate (noticable when scrolling the map) and made the debug build actually playable since a long time) Suggestions for furter optimization (if needed in the future)
This discussion was created from the release Release after a round of refactering and optimizing.
Beta Was this translation helpful? Give feedback.
All reactions