Closed rev2nym closed 5 years ago
Thanks! Before entering upon a discussion of this issue, I linked diffs below for convenience. https://github.com/rev2nym/corescript/compare/master...05737849a1adf2650c8f4344f65dae7fd80f5244
See #171. I will see other questions and your proposal later ;-)
Thank you. I understand meaning.
Please check what _framesOnSave
is doing.
_framesOnSave
is not _frameCount
.
_framesOnSave
copies Graphics.frameCount
befor make savedata and _framesOnSave
plugs _frameCount
after load savedata.
So after all _frameCount
and Graphics.frameCount
are the same price.
I think there is something wrong...
...And
If we want measure time, isn't Date.now()
more appropriate?
p.s. By the way, should I send Pull Request of this branch?
I abandoned large modifications to maintain compatibility. I removed the access to $gameSystem by Scene_Base for the time being.
The issue
The present community edition corescript conflict with "MadeWithMv.js" of a plugin bundled by initial project data. The cause is calling
$gameSystem.onFrameUpdate()
fromScene_Base
when$gameSystem
isn't generated yet.$gameSystem.onFrameUpdate()
is the method to update$gameSystem._frameCount
incrementally.$gameSystem
is generated byScene_Boot.start()
. Therefore should not access game objects such as$gameSystem
beforeScene_Boot.start()
.There are several issues here.
Resolution of conflict with "MadeWithMv.js"
However, this conflict is also a defect on the plugin side, so the priority is low.
Shouldn't access game objects from Scene_Base.
It isn't ensured that generation of game objects is complete when
Scene_Base
running. This should be fixed.Is calling
setupNewGame()
fromScene_Boot
appropriate?Though a new game has not started yet in
Scene_Boot
,DataManager.setupNewGame()
is called fromScene_Boot
. So I think this is the most important in this issue probably.Shouldn't it be made
$gameSystem.update()
?When the processing is called to 1 frame once certainly, it's appropriate to make it the
update()
.The use of
$gameSystem._framesOnSave
is unclear.$gameSystem._frameCount
is included in a save file, so_framesOnSave
isn't useful.After all what was the reason
Graphics.frameCount
put out?And what was the reason
Graphics.frameCount
still exist at other parts?Ideas of solution
Then, where should be
setupNewGame()
called from?Plan A Just before transferring to 'Scene_Map' from 'Scene_Title'. Is's made already default. However, only
$gameSystem
has to be generated inScene_Boot
. '$gameSystem' is used inScene_Title
.Plan B Generate
$gameSystem
whenScene_Title.start()
. About other game objects, establishing another Scene class (for example,Scene_Setup
orScene_NewGame
). Generate all game objects when that scene starting. And transfer to first map after that.I think Plan B is better. It can indicate new game clearly.
How access
$gameSystem._frameCount
?Establishing another Basing Scene class (for example,
Scene_GameBase
). Making Scene classes of whole game after title extend newly Scene class established....And consider that later about
$gameSystem._framesOnSave
andGraphics.frameCount
.