Documentation ¶ Index ¶ func Generate(data Data) ([]byte, error) type Data Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func Generate ¶ func Generate(data Data) ([]byte, error) Generate creates a rank card PNG image and returns the bytes. Types ¶ type Data ¶ type Data struct { Username string AvatarPNG []byte // raw PNG bytes (nil for default avatar) Level int CurrentXP int NeededXP int TotalXP int Rank int } Data holds all information needed to render a rank card. Source Files ¶ View all Source files font.gorankcard.go Click to show internal directories. Click to hide internal directories.