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

[AVM1 debug ui] Make some object properties editable #17279

Merged
merged 13 commits into from
Aug 21, 2024

Conversation

crumblingstatue
Copy link
Contributor

@crumblingstatue crumblingstatue commented Jul 27, 2024

Changing object properties can be useful for helping debugging games, or just cheating/general messing around.

Also adds a filter to quickly find fields of interest.

Todo

  • Attempt to add AVM2 support
    AVM2 debug ui code would require significant changes to add editing support, and I want to keep this pull request fairly simple. Perhaps a followup/intermediate step would be some refactoring and unification work on the AVM1 and AVM2 debug UI code.
  • Optionally try to add support to change type of a value
  • Try using WString as key instead of String

Screenshot of what it looks like:
image

@crumblingstatue crumblingstatue force-pushed the avm1-debug-object-edit branch from 187ed85 to 107ae4c Compare July 30, 2024 17:02
@crumblingstatue crumblingstatue changed the title [Draft] [debug ui] Make some object properties editable [Draft] [AVM1 debug ui] Make some object properties editable Aug 1, 2024
@crumblingstatue crumblingstatue force-pushed the avm1-debug-object-edit branch 2 times, most recently from 63790e4 to 66fd10f Compare August 2, 2024 17:54
@crumblingstatue crumblingstatue marked this pull request as ready for review August 2, 2024 17:54
@crumblingstatue crumblingstatue changed the title [Draft] [AVM1 debug ui] Make some object properties editable [AVM1 debug ui] Make some object properties editable Aug 2, 2024
mutation: &Mutation<'gc>,
) -> Option<Value<'gc>> {
let mut new = None;
egui::ComboBox::new(egui::Id::new("value_combo").with(key), "Type")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Perhaps the "Type" label is a bit redundant, and the dropdown menu is obvious enough without the label.

Copy link
Contributor

@Dinnerbone Dinnerbone left a comment

Choose a reason for hiding this comment

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

Thank you! LGTM

@Dinnerbone Dinnerbone force-pushed the avm1-debug-object-edit branch 2 times, most recently from 6b3a55c to a0c758d Compare August 21, 2024 20:35
@Dinnerbone Dinnerbone enabled auto-merge (squash) August 21, 2024 20:35
@Dinnerbone Dinnerbone force-pushed the avm1-debug-object-edit branch from a0c758d to 79817ee Compare August 21, 2024 20:49
@Dinnerbone Dinnerbone force-pushed the avm1-debug-object-edit branch from 79817ee to 3762523 Compare August 21, 2024 20:49
@Dinnerbone Dinnerbone merged commit 73919c7 into ruffle-rs:master Aug 21, 2024
17 checks passed
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.

2 participants