Skip to content

bucccket/BrawlhallaLanguageEdit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

BrawlhallaLanguageEdit

How To Use

This wrapper implements deserialization and serialization of the language.#.bin files

To use it just construct a new LangFile object. You can treat the object like a dict, when acessing and modifying items.

Example

Example.py:

from DecodeLang import LangFile

if __name__ == "__main__":
    langfile = LangFile("language.1.bin") # open file
    langfile.FromTextFile("Examples.txt") # read a list of new entries. This is NOT reliable
    langfile["test"] = "test" # create new entry
    langfile["UI_PHASE_DESCRIPTION_SUCCESS_NONE"] = "Launched your mom into space" # change existing entry
    print(langfile['MirageColorSchemeType_Black_DisplayName']) # read entry
    langfile.Save("language.1.bin.edit") # save file
    langfile.Dump("language.1.dump")

Examples.txt:

ColorSchemeType_Ranked2_DisplayName=Goldforged
MonikerType_Account17=Legend XII
EmojiType_VDayNaiHeart_DisplayName=Date Night Heart
UI_Account_Linking_Header=Account Linking
SevenColorSchemeType_Summer_DisplayName=Seven Heatwave
CostumeType_MadKing_DisplayName=The Mad King

Documentation

LangFile( filepath )

Opens language.#.bin file and parses it

Save( filepath )

Saves LangFile to path specified

Dump( filepath )

Dumps file contents encoded as UTF8 strings as KVP

FromTextFile( filepath )

Loads a textfile that is delimited with an = like in the example above

About

Simple Python Wrapper For Brawlhalla Language Files

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages