Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Character ¶
type Character struct { *Entity Name string `json:"name"` Description string `json:"description"` Race Race `json:"race"` Class Class `json:"class"` }
Character header data is an abbrevated version of the character sheet
type CharacterRace ¶
type CharacterRace int
CharacterRace type
func (CharacterRace) String ¶
func (cr CharacterRace) String() string
type CharacterSheet ¶
type CharacterSheet struct { *Entity `bson:",inline"` Name string `json:"name"` Description string `json:"description"` Race Race `json:"race"` Class Class `json:"class"` CurrentHitPoints int32 `json:"currentHitPoints"` MaxHitPoints int32 `json:"maxHitPoints"` ArmorClass int32 `json:"armorClass"` Created time.Time `bson:"created" json:"created,omitempty"` Attributes []*Attribute `bson:"attributes" json:"attributes,omitempty"` PersonalityTraits string `json:"personalityTraits,omitempty"` }
CharacterSheet data
func (*CharacterSheet) AsCharacter ¶
func (cs *CharacterSheet) AsCharacter() *Character
AsCharacter creates a new character from charactersheet
type Party ¶
type Party struct { *Entity `bson:",inline"` Name string `json:"name"` Created time.Time `bson:"created,omitempty" json:"created,omitempty"` Characters []primitive.ObjectID `bson:"characters,omitempty" json:"characters,omitempty"` }
Party data
type User ¶
type User struct { *Entity `bson:",inline"` // main *unique* reference id, its additional to ID because it might be a list of reference ids in the future so a user // can merge multiple accounts (refids) into the same user object RefID string `json:"refid,omitempty"` Name string `json:"name"` Nickname string `json:"nickname"` Email string `json:"email"` Created time.Time `bson:"created" json:"created,omitempty"` LastSeen time.Time `bson:"lastSeen" json:"lastSeen,omitempty"` Picture string `json:"picture"` // is set to false after the first PUT request IsNewUser bool `json:"isNewUser"` }
User connects to login credentials to a user object
Click to show internal directories.
Click to hide internal directories.