Open
Conversation
Before it would complain about Nuget packages not being installed because it wasn't looking for it relative to `$(SolutionDir)`.
Don't have to change TestBench includes and enTT directory because it is more reliable to use the current paths.
Use default ctor and ctor with the specified params
Also: - Make GameObject's dtor virtual - Make the c_gameInstance pointer constant - Assign Size to the game object's entity automatically
- Move some funcs definitions to the header files - Remove blank line between `pragma` and first `include` - Use ternary operator in some returns - Remove extra blank lines at the end of the files - Make some iterators (in conditions) constant - Small fixes to `Game`
We don't need this at all since it makes animations inaccurate. Nobody expects animations to be rounded just like nobody don't expect your TV to render the next frame before it should.
- Make unused params anonymous - Remove std::optional for deltaTime param - Remove extra conversions in RenderSystem::update - Simplify RandomPositionSystem::update - Minor fixes and improvements
Removed unused `this` from lambda, remove blank line at the end of file, remove gap between type name and ref symbol
- Remove check on `SDL_WINDOW_FULLSCREEN` (can't reproduce graphic bug) - Combine and pack params (by using components::Size, components::Position, std::pair and std::tuple) - Prevent SDL to be unloaded if there are alive Game objects - Fix messages - Determine what image formats were not loaded - Move some funcs definition inside the class definition - Add simple docs (OMG, really?) for most functions
- Use uint64_t for time instead of double - Make Timer header-only - Mark `Timer::start` as deprecated
It also allows us to use the Windows subsystem without issues.
This will result in a cross-dependent situation where the packages cannot be downloaded without loading the project, but the projects need the packages to be downloaded before being able to load.
936cb45 to
06b8f54
Compare
Storing time into `int` is always a bad idea. There are honestly times where we need to use times lower than 1ms. The performance/memory improvements of using an integer is not worth the accuracy loss.
kasmacioma
reviewed
Oct 1, 2019
| // std::unordered_map<int, Sprite> animationFrames; // Frames can be inserted in any order as long as the correct number is given. | ||
|
|
||
| private: | ||
| double m_lastUpdateTime = 0.0; |
kasmacioma
reviewed
Oct 1, 2019
| double m_lastUpdateTime = 0.0; | ||
| double m_lastUpdateTime = 0; | ||
| size_t m_currentFrame = 0; | ||
| double m_frameTime = 0.0; |
kasmacioma
reviewed
Oct 1, 2019
| } | ||
|
|
||
| void setFPS(double fps) { | ||
| setFrameTime(1000 / fps); |
Contributor
Author
There was a problem hiding this comment.
Oops. Strangely I don't remember doing any of that since I am in the habit of adding the .0s.
Maybe it's because of my quick revert in the timer..
- Remove blank line between #pragma once and #include - Remove unused headres - Game::exit now will signal if exit was successful or not. - Add some missed .0 for double values - Remove explicit values in TextStyle::BlendingMode - Make renderer as const in TextureStore's ctor - Fix indentations - Use array instead of vector in AnimationChangerSystem
kasmacioma
previously approved these changes
Oct 5, 2019
| namespace bloom::components { | ||
| struct Size { | ||
| Size(int w = 1, int h = 1) : w(w), h(h) {} | ||
| Size() : w(0), h(0) {} // or -1? |
fda73b8 to
392fd7d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.