mirror of
https://github.com/asphyxia-core/plugins.git
synced 2026-03-21 17:34:46 -05:00
12 lines
650 B
TypeScript
12 lines
650 B
TypeScript
import { IBst2Player } from "../../models/bst2/profile"
|
|
import { KITEM2 } from "../../utility/mapping"
|
|
import { toFullWidth, toHalfWidth } from "../../utility/utility_functions"
|
|
|
|
export function readPlayerPostProcess(player: KITEM2<IBst2Player>): KITEM2<IBst2Player> {
|
|
if (player.pdata.base?.name != null) player.pdata.base.name["@content"] = toFullWidth(player.pdata.base.name["@content"])
|
|
return player
|
|
}
|
|
export function writePlayerPreProcess(player: KITEM2<IBst2Player>): KITEM2<IBst2Player> {
|
|
if (player.pdata.base?.name != null) player.pdata.base.name["@content"] = toHalfWidth(player.pdata.base.name["@content"])
|
|
return player
|
|
} |