Unity .save Editor

0 views
Skip to first unread message

Maribeth Seagers

unread,
Aug 5, 2024, 2:45:26 PM8/5/24
to woodcceabsentdes
Iam creating a custom editor. Variables do not seem to save when entering play mode or when recompiling scripts. The unity documentation is very unclear and solutions on the web have been pointing in many directions. Can someone please give us a simple and up to date answer on how to save custom editor variables?

In the latter case, you need to actually write the changes back to the serialized object- use EditorGUI.BeginChangeCheck(), then do your property fields, then EditorGUI.EndChangeCheck() and serializedObject.ApplyModifiedProperties() if anything was changed. ApplyModifiedProperties is what actually writes the changes back to the serialized object.


It seems to be permanently saving the the variables now. Thanks alot! There is tons of confusion on how to save variables for custom editors. This thread should be pinned so people can see the clearest solution.


Like Save Editor? Support us and help shape its future! With your generous contributions, we can continue enhancing our platform and work on adding the games YOU want. By becoming a patron, you'll be a crucial part of our development process, unlocking new possibilities for customizing your gaming experience. Don't miss this opportunity - join our community today and make your voice heard!


A save editor is a software tool that allows you to modify every aspect of your game save files without losing any data. The online save editor is the ultimate tool for customizing your favorite games. With support for popular formats like Ren'Py, RPG Maker MV/MZ/VX/XP, NaniNovel, and JSON, our editor is compatible with a wide range of games. Save Editor ensures that you never lose any data and makes it easy to make changes to your game saves.


With a powerful search feature, you can quickly find the values you need to customize. SaveEditor.online gives you complete control over your gaming experience and unlocks new possibilities. Try it out today and start taking your gaming to the next level!


The save editor prioritizes safety and security and is designed to make modifying your game saves as safe as possible. However, it's always a good idea to make a backup of your original save file before using the editor, just in case something goes wrong. This will ensure that you can revert to your original save file if any issues arise.


Our editor is designed to be non-destructive, meaning that it won't affect your original game or save files. Instead, our tool creates a copy of the original save file and makes changes to that copy. This way, you can make changes to your game saves without the risk of data loss or corruption.


While using our save editor, you should also be careful not to modify any fields that you're unsure about. Some game saves have complex structures and interdependencies, and modifying the wrong field could cause issues with your game. However, with Save Editor's user-friendly interface and powerful search feature, you can quickly and easily find and modify the fields you need to customize.


In summary, while SaveEditor.online is designed to be safe and secure, it's always a good idea to make a backup of your original save file before using the editor. With our non-destructive editing and powerful search features, you can safely and easily customize your game saves to your liking.


You can edit anything from in-game resources like money, level, and progress to various game settings. Our tool allows you to view and change all the information you need without removing any data. However, we recommend creating a backup before making any changes to avoid losing progress. Try it out today and take control of your gaming experience!


Our search feature is designed to be both powerful and versatile, providing you with the ability to efficiently locate any value or variable in your save file. With multiple search modes and filters, you can easily find the information you need to customize your gaming experience. Here's an overview of what our search function offers:


For a detailed, step-by-step guide on how to make the most of our search feature, please refer to our comprehensive instruction. This guide will help you utilize our search functionality effectively and customize your gaming experience like never before.


We understand that having the ability to undo changes made to your game save files is an important feature for a better user experience. Currently, our editor does not have a built-in undo feature. However, we offer a "Show only changed fields" checkbox that allows you to filter and see all of the changes you've made to your save file.


By using this feature, you can observe all of the changes you've made and manually reset any fields back to their original values. While this may not be as convenient as an undo feature, it can still be a helpful way to revert any unwanted changes.


We want to assure you that we are actively working on adding an undo feature to our editor in the near future. We are committed to providing the best possible user experience, and we understand the importance of having this feature for our users. In the meantime, we recommend that you use the "Show only changed fields" checkbox to help you keep track of your changes and make it easier to manually reset any fields if needed.


The UI builder modifies the data used by the editor directly in memory with the help of the live reload of the asset. That new information is then saved to file when you actually save in the UI builder. If you modify the data in the meantime, the editor will reimport and override the changes not yet saved in the Ui builder, and you can lose some modification.


@sebastiend-unity I am also encountering this behaviour in Unity 2022.2.6f1. (Due to ECS-related incompatibilities I am not yet able to upgrade to the most recent version of the editor, so it is possible that it has been fixed.)


Frequently, when I save in the UI Toolkit editor, the file will immediately revert to the most recent saved state. I am not touching the UI Toolkit files with any other program. No popup or console message is displayed, but I found this thread when searching for others who had the issue.


Like Sam_Bear asked, is there anything I can do to provide useful diagnostic information and solve this issue? It is easy to forget to hit save after every action, and this makes any UI Toolkit work incredibly frustrating.


I am using Unity UI Toolkit to create an editor window, the problem is when I make a change in the code and unity recompile it, I lose every thing (values) in the editor window. I am using a listview of objectfields and vector3 and toggle elements. How do I save elements values between compiles (or when I close and reopen the editor window)?


I need to rewrite the whole thing from scratch, because I'd like to deserialize the save files completely and make it possible to edit literally everything stored in there, which is going to require a lot of work (have a look at a verbose version of a save file). And since they recently said they're planning on fixing some issues related to save game mechanism, I'd rather wait for a final or almost final version of it.


Updating save loc is not that big a deal (we can manually copy saves to and from the old location), but updating the core functionality (e.g. editing of gold, xp, attributes) would be very welcome. People like me who to experiment with custom parties would higly appreciate that, I am sure.


Just noticed this thread and wanted to say great work! Anything that allows me to edit my camping supplies has my full support (and gold, why did I never consider gold before now? I am SO going to upgrade the hell out of my stronghold.)


So having seen this post I decided that I would try to port this project over to visual c# (especially as bester had voiced his disdain at having made it in unity), it's taken a couple of days but i'm at a point now where I think I have a relatively functional editor.


*** At this point I have to mention that a good chunk of the code was taken from Besters project (due to him saying it was open source), soa huge amount of credit must be given to him for providing the basic code and functions to interrogate and update the save files. At no point am I claiming that all of the code in this project is my own, although a fair chunk of it is. ***


The only problem is that I completely forgot about the backer cutoff date and never purchased to access to the beta. Currently i'm testing the editor with savegames that people have uploaded to the forums but that presents a lot of issues in that I have no way to compare what I see in the editor to what the actual values are in the game.


For things like basic stat editing i'm pretty sure it should work ok, but for more complicated things like adding or removing feats,spells, abilities and items I have no way of verifying that what I am making is going to work.


I have a bit more work to do before the program will be truly standalone and at a point where I am happy with it so I won't upload it yet (probably about another 2 days work), however I will ask that if any of the higher level backers have any spare beta keys they would be willing to donate (or trade) to me they would be helping to improve the editor far past what I could ever do without beta access. If this is the case then please PM me. Please see below for some screenshots of the work in progress:

3a8082e126
Reply all
Reply to author
Forward
0 new messages