Documentation ¶
Index ¶
- Constants
- func Create(stats *AmmoArmorStatistics) error
- func GetAll(opts *Options) (*model.Result, error)
- func GetByRefs(ammo, armor []string, r *RangeOptions, opts *Options) (*model.Result, error)
- func Remove(id string) error
- func Replace(id string, stats *AmmoArmorStatistics) error
- type AmmoArmorStatistics
- type ItemRef
- type Options
- type RangeOptions
- type Statistics
Constants ¶
View Source
const Collection = "statistics.ammunition.armor"
Collection indicates the MongoDB feature collection
Variables ¶
This section is empty.
Functions ¶
func Replace ¶
func Replace(id string, stats *AmmoArmorStatistics) error
Replace replaces the data of an existing entity
Types ¶
type AmmoArmorStatistics ¶
type AmmoArmorStatistics struct { ID objectID `json:"_id" bson:"_id"` Ammo objectID `json:"ammo" bson:"ammo"` Armor ItemRef `json:"armor" bson:"armor"` Distance uint64 `json:"distance" bson:"distance"` PenetrationChance [4]float64 `json:"penetrationChance" bson:"penetrationChance"` AverageShotsToDestruction Statistics `json:"avgShotsToDestruct" bson:"avgShotsToDestruct"` AverageShotsTo50Damage Statistics `json:"avgShotsTo50Damage" bson:"avgShotsTo50Damage"` Modified timestamp `json:"_modified" bson:"_modified"` }
AmmoArmorStatistics describes the entity of a ammo against armor statistics
func GetByID ¶
func GetByID(id string) (*AmmoArmorStatistics, error)
GetByID returns the entity of the given ID
func (AmmoArmorStatistics) Validate ¶
func (d AmmoArmorStatistics) Validate() error
Validate validates the fields of a ArmorStatistics
type RangeOptions ¶
RangeOptions represents the range options of a query
Click to show internal directories.
Click to hide internal directories.