-
Notifications
You must be signed in to change notification settings - Fork 227
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
TOTK request feature : Autobuilder import/export #228
Comments
Sounds good! |
It will require to export a big chunk of memory as binary or something. |
Sounds like a good challenge :-P |
The save file is very big but it doesn't change when it is unlock : i suppose it is filled with 0 until it is unlocked. If you want maintaining having life, stop playing : it makes too addictive 😉. In fact the game gets better the more one advance (i dont want spoiler you). If you want i can sent my savegame although the creations are simply copy of some already done by developers I add a piece which let me keep as mine. |
Excuse me, how much is their size? |
You can summon small monsters if you change the objects (With big ones you can't press a to build). |
If you can direct me on how to locate size; I can let you know. I am new to the HxD / .sav / hex scene lol. I have some programming experience behind me so ideally; if we can locate this I can potentially chuck a PR in to allow us to export / import these autobuilds. Ideally; we could look to extracting the objects with their positions -> export to json -> and handle it that way. |
It depends of the hex-editor. HxD works great. You can select with the mouse all the bytes and it will show the size on the lower part. You can copy it also We need to know how it kept the favorites for avoid issues (i suppose they have a little mark. We can interchange build this way but for exporting and importing in an accessible way the best is the dev implant on the program. I don't know if it also saves a picture of it. I am agree it would great having a file format to share it: that way we can kept a lot of them organized. |
Looking for favourites was my next task. If we can at least bump up favourites to over 8 that would be a good start. Regarding images; I would assume it's saved somewhere kinda like how the saves work. There is a chance it's generated on the fly as save images are stored within a seperate file. I'll keep you posted with my findings! |
Oh, i didn't read the important part : "For me the size of every build is 6692 bytes (0x1A24) ...... I looking for the String "CmbAct", they are 30 of them all of a fixed size : Mine began on the address D7A94. Probably the favorites are before that block, sadly am no at home. I changed one block of CmbAct with other different of the save2. I looked on both saves but the icon has no changed. Note : i dont know if the schemes are on the savefile also nor the vehicles the monster already have (i doubt that, it will be on one file if the game) ....... No needed for this..... Of course it is no important now but they kept on some way a 3d model. The first object no need the extra information of position and it is no joined. Ii know it is out the scope of the save editor which only need to extract/import the full chunk and add the picture it is showed,but i am thinking on how deep the game is and all options it gives for modders and new proyects. |
Yes I noticed a lot of spacing between each history item also. I assumed that the way they are saved is how you mentioned; item -> it's rotation -> where it connects via the glue. I haven't been able to locate the favourite info yet. I did a comparison of 2 saves; one with a favourite and one removed and it was difficult to notice the difference; I was hoping there was a flag being set of some sort. Again though, I'm not massively experience in the world of hex or any yuzu modding lol. I'll keep posted on here and look forward to seeing what everyone finds! EDIT: Mine started D7A90 |
I believe the others are on the blocks before that. 8 blocks of size = 0x1a24 (maybe more if it has a flag of favorites but i doubt.) Ah, very useful on HxD: control+G go to |
Got an importer/exporter working already ;-) |
Bravo! Were we in the right direction ? |
You were mising other needed bits for the thumbnail, but other than that yeah, you got the real data size ;-) |
Amazing stuff! Can't wait to see it on master. Are you looking to export it to a better format such as JSON? Means we can create a little database with these and potentially create a system to retrieve and insert users creations with ease! |
If you talk about users can import it easily, it is no needed convert to Json : simply copy the chunk of data, save it on a file and share it(you can see examples on the file I attached).Once the user wants that creation, he/she upload their save file to the web and press the butto: it will replace tone of the builds with the new one. |
I uploaded a very preliminary version. I've tested it and managed to clone one of my designs into other slots, so I figure it's functional.
Enjoy :-) |
I'll give it a shot shortly! Thanks again for your hard work 🤝 |
You are the best! |
Just curious; is the image stored within the data or generated in-game? Would be cool to view the schema on the editor so you know you've selected the correct one! Once again, amazing work! |
Great work! I see you have already discovered the offset of the variables : |
Haha I'm already doing crazy stuff with auto build: https://twitter.com/Tankerbot/status/1665210237266063362 Thanks to that I found where in my save some of my autobuild history is in. The slot names in the current version of the editor makes it hard to tell what they correspond to in game so instead I just searched by actor ID name in my save file and directly and replaced one object with another. It seems I can use longer or shorter names then the original so long as I use 00 hex value to correctly end the string. Anyways I hope eventually the autobuild features eventually let you set position/rotation cooridents for autobuild objects. I tried to spawn something a bit larger and it seems if it overlaps with another object in the autobuild plan it will say there isn't room to build it so that limits me if I can't move them. It doesn't seem to matter if they are too far apart to actually connect. At least with my test of the NPC Zelda object. It just never connected to the korok NPC object and remained where I spawned it. :P Sadly I could not use Korok backpack NPCs in my plan without the camera bugging out and it auto canceling. (normally it spawns a green backpack that doesn't have the korok NPC on it). So no full korok backpack NPC on demand it seems. :( It does seem the autobuild thumbnails are saved as images somewhere. The object swaps I did not alter the thumbnail for it. EDIT: Lol spawned a bokoblin with it. They spawn larger then normal too. The attached backpack korok just vainishes instantly because it it's the green korokless one and since it failed to attach it just vainishes. The bokoblin remained though. A good way to spawn random crap if you want. Seems better then via stables at least. :P Note that the bokoblin would not attack if I spawned him in an area near a stable and one time he just vanishes. After I went out of the safe zone of the stable, he saw me and started attacking. killing him dropped the normal loot for a Bokoblin. |
It is generated in real time.
The thumbnails are generated in real time, but probably the game just loads the environmental object models and ignores the rest.
Sadly, if I ever add editing features, it will be very basic without no 3D model preview, as that sounds almost like another project by itself. |
I do not mind if you guys do some cool research like this, but I'd prefer you to open a new issue for that (even if it's not exactly an issue). Even though no one has complained yet about the autobuilder import/export feature, I want to keep this clean so it's easier for me to track the real issues. Let's leave this current issue for problems and/or CombinedActorInfo structure research and, if you don't mind, open a new one for the rest of playing with actor IDs. |
I believe I successfully created a one object Autobuild plan. I compared some different CmbAct sections and experimented with changing this byte. The first 3 bytes after the header is always 00 00 02 it seems but the byte after that appears to define the object count. I'm fiddling with the next byte to see if that's the plan area size. Setting it to FF broke it and caused a odd camera angle so maybe? I'll play around more with that. I zero'd out the second actor ID and it still works. Though the particular actor I tried to spawn is still too large for the original plan but that's an unrelated issue. Normally zeroing out one of the IDs breaks the entire plan but after changing that byte to 1 on a 2 object plan it worked. I can confirm the difference via zonaite cost. Original plan costed 6 and the modified one is half that at 3. ;) So hopefully that helps in allowing the editor to add/remove new entries to a plan. ;) (Though I wouldn't recommend creating a one object plan unless you are spawning normally unsupported objects with it as normal "greenified" objects despawn immediately since they aren't attached to anything) EDIT: Ok that second byte I was playing with doesn't appear to be plan area size. Not sure what it is. I did manage to get the object to spawn if I hovered it over a certain raised area in the landscape which caused it's rotation to glitch a bit..it might be due to rotation or something since some actors force a certain rotation direction relative to the ground so that might be why some large dynamic stuff like Lynals have a hard time spawning with it. EDIT2: yeah it's definitely a rotation issue. I messed with the rotation with the problematic object a enough and it was starting to let me place it more often. Center of mass/rotation of the plan is likely why some custom Actor IDs aren't getting along with it. ;) Also noticed that my one object plan is basically free as long as it's a non standard object. The UI says it's 3 zonai but for some reason it seems to semi cancel on spawn and doesn't take my zonaite ( I have to guess it's expecting the object to despawn itself but since it's a non fusable object not normally allowed in autobuilds that never happens since it seems normal fuseable objects handle that behavior on their own and it's not the autobuild system deleting the object?). Anyways that's off topic now so I'll keep it at that. :D |
Hello, it seems the limit of objets you can use for one build are 21. |
What program do you use to edit the autobuild files? |
That seems HxD |
Yeah used a hex editor to manually modify my Autobuild data. There isn't a tool for that yet. |
Guys amazing work! Is there a place where we can download autobuilds? I do need a perfect mk2, nothing more. My own creation is always not going straight. |
You find anything? |
Not really. You got a save file with a perfect mk2? |
Nope lol i was looking for good builds lol |
Write a tutorial and create a thread on GBAtemp and https://www.reddit.com/r/HyruleEngineering/ to let people know of the feature. |
Hello, I want suggest to add the code for rendering the object. |
Please Stop!. Excuse me marcrobledo and the rest who are researching for the proyect : i have received too much messages of two persome begging... |
Yes, but it would be really beneficial to convert to JSON so that we can edit builds externally. |
So there is tools to edit Autobuild Exports externally? |
They are already a pluggin for view them on toolbox. |
Wait, you know of an already existing .totkab reader? Where might I find it? |
It is a toolbox pluggin : About the standalone viewer + editor i saw it on the zelda tears mods |
|
The thumbnails appear to be generated at creation time. I exported a build, then reimported it into a different slot and the thumbnail never changed. It still shows the thing that used to be in that slot. They have to be stored somewhere in the save. |
No, they are regenerated in real time. I assume you are using an emulator, which cache works a little different than real hardware, that's why the thumbnails are not updating. Also remember, everytime you load an emulator with a modded TOTK savegame, you must close all explorer windows. |
I am, in fact, using real hardware. So it clearly is not rendering in real time. EDIT: There have been two blood moons, no change. I restarted the game, no change. I restarted the Switch, no change. I shut it down completely and cold-booted into OFW, no change. EDIT2: Went into the system settings and manually cleared the cache, no change |
An wonderful work! |
There is now a website to share builds and also .cai files: If you guys know of any other places that share .cai files, please share. :) |
I can assure thumbnails are not stored anywhere in the savegame but as cached images. Don't know how to trigger a refresh though.
The blueprint dropdown should show up in the same order as in-game's history. But anyway, keep reading... ;-)
Yeah! I already got in touch with the author, and we have permission to link it in the editor. So... here it is the new update in the editor!
|
I can confirm this behavior (I´m using OLED Switch, not emulator). I imported builds from HyruleWorks and the thumbnails didn´t change, they still show my old autobuilds. |
For anyone running Yuzu, you should be able to get the autobuild icons to update by right-clicking on the game, then clicking Remove --> Remove Cache Storage. |
Nice, thank you @a-plastic-bag . It would be great if there was a way to wipe cache on real hardware. I'm not into Switch hacking but... is there a homebrew that can solve this by any chance? |
I recently edited my save and added a few weapons. |
Hello, first thanks for your great work!
I would love ask if it could be added a way to extract and injection devices which are on the Autobuilder memory, this way players could share their creations.
Thanks!
The text was updated successfully, but these errors were encountered: