Skip to content
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

Can't open a lone zobj properly without opening a rom first #1

Open
Dragorn421 opened this issue Jul 4, 2023 · 0 comments
Open

Can't open a lone zobj properly without opening a rom first #1

Dragorn421 opened this issue Jul 4, 2023 · 0 comments

Comments

@Dragorn421
Copy link
Collaborator

Someone who isn't me had an issue viewing a single .zobj until they opened a rom

error trace:

Consultez la fin de ce message pour plus de détails sur l'appel du débogage
juste-à-temps (JIT) à la place de cette boîte de dialogue.

************** Texte de l'exception **************
System.NullReferenceException: Object reference not set to an instance of an object.
   at Z64.Forms.SkeletonViewerForm..ctor(Z64Game game, Int32 curSegment) in D:\Z64Utils\Z64Utils\Forms\SkeletonViewerForm.cs:line 75
   at Z64.Forms.ObjectAnalyzerForm.openSkeletonViewer() in D:\Z64Utils\Z64Utils\Forms\ObjectAnalyzerForm.cs:line 679
   at Z64.Forms.ObjectAnalyzerForm.listView_map_DoubleClick(Object sender, EventArgs e) in D:\Z64Utils\Z64Utils\Forms\ObjectAnalyzerForm.cs:line 176
   at System.Windows.Forms.Control.OnDoubleClick(EventArgs e)
   at System.Windows.Forms.ListView.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, WM msg, IntPtr wparam, IntPtr lparam)

this puts the error at
https://github.com/zeldaret/Z64Utils/blob/v2.2.1/Z64Utils/Forms/SkeletonViewerForm.cs#L75

or in master at:

_renderer.Memory.Segments[4] = F3DZEX.Memory.Segment.FromBytes("gameplay_keep", game.GetFileByName("gameplay_keep").Data);

It gave me the hint to suggest loading a rom before opening the zobj
And that worked

So there should be a check to not try to load gkeep if it's not available (no rom loaded)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant