-
-
Notifications
You must be signed in to change notification settings - Fork 539
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Enhancement] Decouple all global variables from extern in true singleton #325
Merged
dudantas
merged 14 commits into
opentibiabr:main
from
beats-dh:Decouple-extern-in-true-singleton
Apr 24, 2022
Merged
[Enhancement] Decouple all global variables from extern in true singleton #325
dudantas
merged 14 commits into
opentibiabr:main
from
beats-dh:Decouple-extern-in-true-singleton
Apr 24, 2022
Conversation
This file contains 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
lgrossi
approved these changes
Apr 23, 2022
dudantas
approved these changes
Apr 23, 2022
Kudos, SonarCloud Quality Gate passed! |
luan
pushed a commit
that referenced
this pull request
Jul 11, 2023
…eton (#325) All the global variables * g_* were decoupled to true singletons, reducing the dependencies between the objects and simplifying the amount of calls and instances. They used to be partial singletons mixed with global variables, that way we have one, and only one instance that is accessed via the getInstance methods, that are now the * g_* functions. Changes: g_actions g_chat g_config g_creatureEvents g_database g_databaseTasks g_decay g_dispatcher g_events g_game g_globalEvents g_luaEnvironment g_modules g_monsters g_moveEvents g_npc g_npcs g_RSA g_scheduler g_scripts g_spells g_talkActions g_vocations g_weapons The * g_luaEnvironment has been decoupled using inline, new feature of c++17
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Area: Source
Priority: Low
Minor impact
Status: Pending Review
This PR or Issue requires a review
Status: Pending Test
This PR or Issue requires more testing
Type: Enhancement
New feature or request
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.
All the global variables * g_* were decoupled to true singletons, reducing the dependencies between the objects and simplifying the amount of calls and instances. They used to be partial singletons mixed with global variables, that way we have one, and only one instance that is accessed via the getInstance methods, that are now the * g_* functions.
Changes:
The * g_luaEnvironment has been decoupled using inline, new feature of c++17