Python Forum

Full Version: TypeError: a bytes-like object is required
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Ah ok, I think I have not understood the purpose of the program. I thought it took elements from the source code to convert the PIC file format into human readable, but in the below structure:

Pickup Locations (*.PIC):
 
Magic Number: uint32
Pic Version Number: uint32
 
NumRegenPoints: int16
{
    gen_type: int16
      regen_type: int16
       gen_delay: float
       life_span: float
             pos: VECTOR
             {
               x: float
               y: float
               z: float
             }
           group: int16
            Type: int16
      TriggerMod: int16
}
From what you have said even if it executed properly once it is in the YAML format it will still be mostly useless in relation to the above structure?
You can read a YAML file and it will output in binary pic format. You decide if that is worthless or not.
Sorry I am a little confused, I thought the PIC file format was just something assigned by the original programmers because it was short for "pickup". Is PIC a type of binary?
It is probably not a standard format, but it would still be a file format as far as your application is concerned. Binary files formatted in a certain way can be used by your program. May as well give the format a name.
Pages: 1 2