Adding modding folder with a hacked build.

This commit is contained in:
ml
2026-09-26 08:53:08 +02:00
parent cdb960dc71
commit c91080aba7
755 changed files with 50424 additions and 0 deletions
@@ -0,0 +1,33 @@
package text
type tabledCodepage struct {
tableToRune []rune
tableToByte map[rune]byte
}
func (cp *tabledCodepage) Encode(value string) []byte {
result := make([]byte, 0, len(value)+1)
for _, c := range value {
mapped, known := cp.tableToByte[c]
if !known {
mapped = cp.tableToByte['?']
}
result = append(result, mapped)
}
result = append(result, 0x00)
return result
}
func (cp *tabledCodepage) Decode(data []byte) string {
runes := make([]rune, 0, len(data))
for _, value := range data {
if value != 0x00 {
runes = append(runes, cp.tableToRune[value])
}
}
return string(runes)
}