Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
in "level.lua"
the variables : "exp" (& therefore "max_exp")
are unused, and they are not global but "local"
therefore those two lines could be deleted or commented out
I'm not an expert at code execution speed but the repetition of "inst:RemoveTag" seems terribly inefficient or at the very least it makes the code longer & a pain to maintain.
I suggest a single function & a single loop. I have concrete code thoughts about this, but before I write them out. I'd like to know if you're interested & active at all. Otherwise there's no point.
Thanks.
I believe the code should be able to be shortened by at least 400 lines
which will make it easier to read & maintain should you ever want to change the number of levels positively or negatively
edit: preliminary rewrites, the file falls to about 37 lines with comments ! no tests done though, so might need more work.
while I respect the huge amount of work that this mod is, also nice art & such
I believe this project needs another developper to help out with the coding aspect
a concrete example :
if sleeper.music <=100 then
sleeper.music = sleeper.music + 50
if sleeper.music >=100 then
sleeper.music = sleeper.music *0 + 100
sleeper:AddTag("switlight")
end
elseif sleeper.music >=100 then
sleeper.music = sleeper.music *0 + 100
sleeper:AddTag("switlight")
end
basically this just adds 50 if < 50 else it's 100 & addtag ...
so here one just removed 4 lines of code
also fail to see why multiply by 0 since the result will always be 0 no matter what