Skip to content

Add script to restart the running XBE#62

Open
JayFoxRox wants to merge 1 commit intomasterfrom
restart
Open

Add script to restart the running XBE#62
JayFoxRox wants to merge 1 commit intomasterfrom
restart

Conversation

@JayFoxRox
Copy link
Copy Markdown
Owner

@JayFoxRox JayFoxRox commented Aug 9, 2018

Depends on xboxpy updates: JayFoxRox/xboxpy#4

This adds functions to restart the current running XBE.
While this functionality will eventually be added to xboxpy, it's good to have this implementation for testing / messing around.

It works fine using the nxdk-rdt backend. However it seems to crash using xbdm backend.

The implementation is slightly ugly because the CALL never returns. We need a noreturn option for CALL in xboxpy, nxdk-rdt and xbdm.

#!/usr/bin/env python3

# Run this from a clean Xbox environment (= not while a game is running)
# NXDK-RDT is a good environment
Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Outdated comment

launch_data_page_addr = read_u32(launch_data_page_addr_addr)
print("LaunchDataPage: 0x%08X [@ 0x%08X]" % (launch_data_page_addr, launch_data_page_addr_addr))

#FIXME: Allocate LaunchDataPage
Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already done

xbe_path, sep, xbe_name = filename_str.rpartition('\\')
xbe_launch_str = xbe_path + ";" + xbe_name
print(xbe_launch_str)
#aafoiahfoisahf
Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be removed

# uint32_t flags;
# uint8_t pad[492];
# uint32_t launch_data[3072];
#}* LaunchDataPage;
Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link to xboxdevwiki instead

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

Successfully merging this pull request may close these issues.

1 participant