Documentation ¶
Index ¶
- Variables
- func Buyable(Bases []GoodAtBase) bool
- func DistanceForVecs(Pos1 *semantic.Vect, Pos2 *semantic.Vect) (float64, error)
- func Empty(phrase string) bool
- func GetMaxRadius(Size *semantic.Vect) (float64, error)
- func GetPricePerVoume(price int, volume float64) float64
- func InitRegexExpression(expression string) *regexp.Regexp
- func IsAnyVignetteWithinNPCSpawnRange(system *systems_mapped.System, ...) bool
- func NameWithSpacesOnly(word string) bool
- type Ammo
- type Base
- type BaseInfo
- type BaseMissions
- type Commodity
- type CompatibleIDsForTractor
- type CounterMeasure
- type DamageBonus
- type DiffToMoney
- type DiscoveryTechCompat
- type EnemyFaction
- type Engine
- type EquipmentSlot
- type Exporter
- func (e *Exporter) Export() *Exporter
- func (e *Exporter) GetAmmo(ids []Tractor) []Ammo
- func (e *Exporter) GetAtBasesSold(commodity GetAtBasesInput) []GoodAtBase
- func (e *Exporter) GetBaseInfo(base_nickname universe_mapped.BaseNickname) BaseInfo
- func (e *Exporter) GetBases() []Base
- func (e *Exporter) GetCommodities() []Commodity
- func (e *Exporter) GetCounterMeasures(ids []Tractor) []CounterMeasure
- func (e *Exporter) GetEngineSpeed(engine_info *equip_mapped.Engine) int
- func (e *Exporter) GetEngines(ids []Tractor) []Engine
- func (e *Exporter) GetFactions(bases []Base) []Faction
- func (e *Exporter) GetGuns(ids []Tractor) []Gun
- func (e *Exporter) GetInfocardName(ids_name int, nickname string) string
- func (e *Exporter) GetMines(ids []Tractor) []Mine
- func (e *Exporter) GetMissiles(ids []Tractor) []Gun
- func (e *Exporter) GetMissions(bases []Base, factions []Faction) []Base
- func (e *Exporter) GetScanners(ids []Tractor) []Scanner
- func (e *Exporter) GetShields(ids []Tractor) []Shield
- func (e *Exporter) GetShips(ids []Tractor) []Ship
- func (e *Exporter) GetThrusters(ids []Tractor) []Thruster
- func (e *Exporter) GetTractors() []Tractor
- func (e *Exporter) NewEnemyFaction(faction Faction, npc_ranks []int) EnemyFaction
- type Faction
- type GetAtBasesInput
- type GoodAtBase
- type Gun
- type Infocard
- type InfocardKey
- type Infocards
- type MarketGood
- type Mine
- type Missile
- type MissioNFaction
- type OptExport
- type Rephack
- type Reputation
- type Scanner
- type Shield
- type Ship
- type Thruster
- type Tractor
Constants ¶
This section is empty.
Variables ¶
View Source
var LogOgE = math.Log10(math.E)
View Source
var Pi180 = 180 / math.Pi // number turning radians to degrees
View Source
var TypeClassRegex *regexp.Regexp
Functions ¶
func Buyable ¶ added in v0.33.0
func Buyable(Bases []GoodAtBase) bool
func DistanceForVecs ¶ added in v0.54.0
func GetPricePerVoume ¶ added in v0.57.0
func InitRegexExpression ¶ added in v0.24.0
func IsAnyVignetteWithinNPCSpawnRange ¶ added in v0.55.0
func IsAnyVignetteWithinNPCSpawnRange(system *systems_mapped.System, npc_spawn_zone *systems_mapped.MissionPatrolZone) bool
func NameWithSpacesOnly ¶ added in v0.15.0
Types ¶
type Ammo ¶ added in v0.49.0
type Ammo struct { Name string Price int HitPts int AmmoLimit int Volume int Nickname string NameID int InfoID int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulAmmo ¶ added in v0.49.0
type Base ¶
type Base struct { Name string Nickname string FactionName string System string SystemNickname string StridName int InfocardID int Infocard InfocardKey File utils_types.FilePath BGCS_base_run_by string MarketGoods []MarketGood Pos conftypes.Vector Missions BaseMissions }
func FilterToUserfulBases ¶ added in v0.33.0
type BaseMissions ¶ added in v0.52.0
type Commodity ¶ added in v0.19.0
type Commodity struct { Nickname string Name string Combinable bool Volume float64 NameID int InfocardID int Infocard InfocardKey Bases []GoodAtBase PriceBestBaseBuysFor int PriceBestBaseSellsFor int ProffitMargin int }
func FilterToUsefulCommodities ¶ added in v0.34.0
type CompatibleIDsForTractor ¶ added in v0.58.0
type CounterMeasure ¶ added in v0.35.0
type CounterMeasure struct { Name string Price int HitPts int AIRange int AmmoLimit int Lifetime int Range int DiversionPctg int Lootable bool Nickname string NameID int InfoID int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulCounterMeasures ¶ added in v0.35.0
func FilterToUsefulCounterMeasures(cms []CounterMeasure) []CounterMeasure
type DamageBonus ¶ added in v0.21.0
type DiffToMoney ¶ added in v0.52.0
type DiscoveryTechCompat ¶ added in v0.44.0
func CalculateTechCompat ¶ added in v0.44.0
func CalculateTechCompat(Discovery *configs_mapped.DiscoveryConfig, ids []Tractor, nickname string) *DiscoveryTechCompat
type EnemyFaction ¶ added in v0.55.0
type Engine ¶ added in v0.29.0
type Engine struct { Name string Price int CruiseSpeed int CruiseChargeTime int LinearDrag int MaxForce int ReverseFraction float64 ImpulseSpeed float64 HpType string FlameEffect string TrailEffect string Nickname string NameID int InfoID int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulEngines ¶ added in v0.33.0
type EquipmentSlot ¶ added in v0.27.0
type Exporter ¶
type Exporter struct { Bases []Base Factions []Faction Infocards Infocards Commodities []Commodity Guns []Gun Missiles []Gun Mines []Mine Shields []Shield Thrusters []Thruster Ships []Ship Tractors []Tractor Engines []Engine CMs []CounterMeasure Scanners []Scanner Ammos []Ammo // contains filtered or unexported fields }
func Export ¶ added in v0.13.0
func Export(configs *configs_mapped.MappedConfigs) *Exporter
func NewExporter ¶
func NewExporter(configs *configs_mapped.MappedConfigs, opts ...OptExport) *Exporter
func (*Exporter) GetAtBasesSold ¶ added in v0.21.0
func (e *Exporter) GetAtBasesSold(commodity GetAtBasesInput) []GoodAtBase
func (*Exporter) GetBaseInfo ¶ added in v0.50.0
func (e *Exporter) GetBaseInfo(base_nickname universe_mapped.BaseNickname) BaseInfo
func (*Exporter) GetCommodities ¶ added in v0.19.0
func (*Exporter) GetCounterMeasures ¶ added in v0.35.0
func (e *Exporter) GetCounterMeasures(ids []Tractor) []CounterMeasure
func (*Exporter) GetEngineSpeed ¶ added in v0.61.0
func (e *Exporter) GetEngineSpeed(engine_info *equip_mapped.Engine) int
func (*Exporter) GetEngines ¶ added in v0.29.0
func (*Exporter) GetFactions ¶ added in v0.13.0
func (*Exporter) GetInfocardName ¶ added in v0.59.0
func (*Exporter) GetMissiles ¶ added in v0.22.0
func (*Exporter) GetMissions ¶ added in v0.51.5
func (*Exporter) GetScanners ¶ added in v0.48.0
func (*Exporter) GetShields ¶ added in v0.24.0
func (*Exporter) GetThrusters ¶ added in v0.25.0
func (*Exporter) GetTractors ¶ added in v0.28.0
func (*Exporter) NewEnemyFaction ¶ added in v0.55.0
func (e *Exporter) NewEnemyFaction(faction Faction, npc_ranks []int) EnemyFaction
Calculates for enemy faction percentage of ships defined in faction_props/npcships.ini If they aren't defined, Freelancer will be showing corrupted no missions when they encounter.
type Faction ¶ added in v0.13.0
type Faction struct { Name string ShortName string Nickname string ObjectDestruction float64 MissionSuccess float64 MissionFailure float64 MissionAbort float64 InfonameID int InfocardID int Infocard InfocardKey Reputations []Reputation Rephacks []Rephack }
func FilterToUsefulFactions ¶ added in v0.33.0
type GetAtBasesInput ¶ added in v0.21.0
type GoodAtBase ¶ added in v0.21.0
type Gun ¶ added in v0.20.0
type Gun struct { Nickname string Name string Type string Price int Class string HpType string IdsName int IdsInfo int HitPts string PowerUsage float64 PowerPerSec float64 Refire float64 Range float64 Toughness float64 IsAutoTurret bool TurnRate float64 Lootable bool RequiredAmmo bool // AmmoPrice int // AmmoBases []GoodAtBase // AmmoName string HullDamage int EnergyDamange int ShieldDamage int DamageType string LifeTime float64 Speed float64 HullDamagePerSec float64 ShieldDamagePerSec float64 PowerUsagePerSec float64 AvgEfficiency float64 HullEfficiency float64 ShieldEfficiency float64 Value float64 Rating float64 Bases []GoodAtBase DamangeBonuses []DamageBonus Missile *DiscoveryTechCompat }
func FilterToUsefulGun ¶ added in v0.34.0
type InfocardKey ¶ added in v0.17.0
type InfocardKey string
type Infocards ¶ added in v0.58.3
type Infocards map[InfocardKey]Infocard
type MarketGood ¶ added in v0.8.0
type Mine ¶ added in v0.23.0
type Mine struct { Name string Price int AmmoPrice int Nickname string IdsName int IdsInfo int HullDamage int EnergyDamange int ShieldDamage int PowerUsage float64 Value float64 Refire float64 DetonationDistance float64 Radius float64 SeekDistance int TopSpeed int Acceleration int LinearDrag float64 LifeTime float64 OwnerSafe int Toughness float64 HitPts int Lootable bool Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulMines ¶ added in v0.34.0
type MissioNFaction ¶ added in v0.52.0
type OptExport ¶ added in v0.13.0
type OptExport func(e *Exporter)
func WithEmptyRecords ¶ added in v0.31.0
func WithEmptyRecords() OptExport
type Reputation ¶ added in v0.13.0
type Scanner ¶ added in v0.48.0
type Scanner struct { Name string Price int Range int CargoScanRange int Lootable bool Nickname string NameID int InfoID int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUserfulScanners ¶ added in v0.48.0
type Shield ¶ added in v0.24.0
type Shield struct { Name string Class string Type string Technology string Price int Capacity int RegenerationRate int ConstantPowerDraw int Value float64 RebuildPowerDraw int OffRebuildTime int Toughness float64 HitPts int Lootable bool Nickname string HpType string IdsName int IdsInfo int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulShields ¶ added in v0.34.0
type Ship ¶ added in v0.26.0
type Ship struct { Nickname string Name string Class int Type string Price int Armor int HoldSize int Nanobots int Batteries int Mass float64 PowerCapacity int PowerRechargeRate int CruiseSpeed int ImpulseSpeed float64 ReverseFraction float64 ThrustCapacity int ThrustRecharge int MaxAngularSpeedDegS float64 AngularDistanceFrom0ToHalfSec float64 TimeTo90MaxAngularSpeed float64 NudgeForce float64 StrafeForce float64 NameID int InfoID int Bases []GoodAtBase Slots []EquipmentSlot BiggestHardpoint []string *DiscoveryTechCompat DiscoIDsCompatsOrdered []CompatibleIDsForTractor }
func FilterToUsefulShips ¶ added in v0.34.0
type Thruster ¶ added in v0.25.0
type Thruster struct { Name string Price int MaxForce int PowerUsage int Efficiency float64 Value float64 Rating float64 HitPts int Lootable bool Nickname string NameID int InfoID int Bases []GoodAtBase *DiscoveryTechCompat }
func FilterToUsefulThrusters ¶ added in v0.34.0
Click to show internal directories.
Click to hide internal directories.