1. GRAnimated

    GRAnimated Advanced Member
    Newcomer

    Joined:
    Jan 9, 2017
    Messages:
    68
    Country:
    United States
    Hey, so i am having a problem with Mario Maker's BFLYT files, some files seem to work, but any file from Mario Maker that I save back as a BFLYT from XMFLYT loses about 2-5kb of data and crashes ingame. Some other BFLYT files from this game will not convert to xmflyt and some won't convert to BFLYT. I provided a zip file containing 2 different files which both don't work.
     

    Attached Files:

  2. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    thanks i will take a look at them
     
  3. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    @GRAnimated I've fixed the problem with the Play_PlayScene_00 file
    I need you to send me the original Edit_Contents_00.bflyt file it looks like its messing up creating the groups in the xml
     
  4. GRAnimated

    GRAnimated Advanced Member
    Newcomer

    Joined:
    Jan 9, 2017
    Messages:
    68
    Country:
    United States
     

    Attached Files:

  5. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    oddly creating the xml from that bflyt did not have the same problems that your xml shows in the groups section i suggest you recreate your xml from the stock file using the 1.0.9 version i just uploaded
     
  6. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    @diddy81 Currently trying to edit some .bflan files from the Switch. Apparently they are little endian which is not supported. Is little endian support planned or am I hosed?
     
  7. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    sorry i have no plans to update this at all also even if it did support little endian its highly unlikely it could convert a file for the switch witch at a guess uses a updated version of the bflan format just like the wii U used a updated version of the wii's files
    your welcome to grab the source code and have a go editing it its written in python
     
  8. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    @diddy81 I see, I'll look into getting it to work with the Switch files. Also, can you make sure I'm looking in the right place for what I want to do? On the Switch, you can edit the starting color of the box that highlights tiles on the homescreen (using Wexos to edit a .bflyt). However, the color is then animated to another target color (light blue) which is not in the .bflyt. I have found the .bflan that controls this animation and want to locate the target color within it. Looking in bflanRead.py, I see the sort of things that are read (seconds, start, end) but I'm not sure where the target color would fit into all of this.

    Thanks for your patience!
     
  9. GRAnimated

    GRAnimated Advanced Member
    Newcomer

    Joined:
    Jan 9, 2017
    Messages:
    68
    Country:
    United States
    After a long time of layout research from me (last post here about stuff from me was from 8/6/2017!), I've figured out some stuff. The tool still doesn't work with SMM's BFLYTs, but they work with the BFLANs great. With the BFLYTs, something in mat1 breaks when converting back with BenzinU.

    Also, for Switch BFLYTs and BFLANs, I've concluded that they're exactly the same, except little endian. There are a few differences in ordering in mat1 and such, too. I think there's a new section that's rarely used, and usd1 has a lot of different uses for being user data.
     
  10. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    the animation could be under a FLVC but will more likely be under a FLMC tag
    there will be a separate set for each RGB value
     
  11. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    It does seem they are quite similar except for the endianess. Another difference I've found is a "FLEU" tag type which doesn't seem to be referenced in BenzinU. Just before this type there is a 4 Byte segment (0x2C00000 in my file's case) which BenzinU is attempting to read as the next tagtype and then crashing. Deleting these 4 bytes let's the file be successfully processed, but obviously I must be losing some data.

    I have not been able to diagnose why this happens. I might have thought the FLTS before the FLEU simply had 4 more bytes now, but there is an earlier FLTS which doesn't cause problems. So I'm unsure.
     
  12. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    Changing the struct.unpack calls to read little endian allows all the files I've tested to be processed without modification, except for the one I mentioned in the post directly above this one.
     
  13. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    @diddy81 Sorry to blow up the thread, but can I pick your brain? I've gotten the majority of .bflans to successfully process with BenzinU by:
    1: Changing struct.unpack calls to expect little endian
    2: Accounting for 8 bytes of extra padding at the end of the pat1header section (I'm literally just incrementing 'pos' by 8)
    3: Changed the 'data_type' to expect 1 and 2 rather than 256 and 512 for triplets and tuples.

    All the files that still fail, fail just before an "FLEU" section (looks like this is new).
    It fails because when looking for the FLEU header, it's actually looking at the 4 bytes just before the FLEU header. These seem to always be 0x2C000000.
    I can manually change the "offset" of any FLEU to 44 rather than 40 and this fixes it, but it's hacky and I want to understand what I'm doing rather than just skipping the 4 bytes that give me issues. Haha.
     
  14. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    if i had to guess i would say its the size of the FLEU section as 2C == 44
    unfortunately working out what things do in a file sometimes hacky is all you have
     
  15. SaulFemm

    SaulFemm Member
    Newcomer

    Joined:
    Oct 25, 2018
    Messages:
    31
    Country:
    United States
    @diddy81 I forked BenzinU, hope that's alright. There didn't seem to be a license specified. So far I've gotten 100% success on converting Switch .bflan files to XML. Conversion from XML to .bflan works on something like 80% of files. Not sure if I'm going to bother with .bflyt's. Here's the repo: https://github.com/AustinHasten/BenzinNX
     
    GRAnimated, I pwned U! and diddy81 like this.
  16. BaamAlex

    BaamAlex Eduard Pinguingummihals!
    Member

    Joined:
    Jul 23, 2018
    Messages:
    2,632
    Country:
    Germany
    Sorry for this question...but what the heck is benzinU? I dont really understand the op?!
     
  17. diddy81

    OP diddy81 Wii Theme Team
    Member

    Joined:
    Mar 14, 2009
    Messages:
    821
    Country:
    its a program to convert the layout files the wii U uses so they can be edited then converted back
     
Draft saved Draft deleted
Loading...

Hide similar threads Similar threads with keywords - BenzinU, Release,