Closed joao-vitor-souza closed 1 year ago
The thing with g_RegistryManager is something else. Since there is no local or so this is a global variable. This way you only have one instance of the Registry Manger and not one for every component that uses it. We should revert that again. Does this make sense for you? The other things are great improvements!
switch back to tab spaces. there is no way to review this properly now. ^^
I used the configs in
.editorconfig
on my Lua extension in VSCode and formatted these files, didn't change anything in the code (only style), except that:In
Registry.lua
andClientBotManager.lua
I fixed the grammar of this variable:USE_COLLITION_RAYCASTS
->USE_COLLISION_RAYCASTS
, and some other grammar stuff on comments;In both
RegistryManager.lua
andRegistryUtil.lua
I standardized the notation of these files with the other ones, likeself._VariableName
;In
ArrayMap.lua
I simplified the for loops comparing the data ofself._Entries
with the passed argument directly;Last, I fixed the
RegistryManager:Get
method, it was never returning thevariable
value, even whenvalue ~= nil
, it returneddefault
. This method is used no where, but now it'll work properly if it's needed.