Table of Contents

Class FVRObject

Namespace
FistVR
Assembly
Assembly-CSharp.dll

This scriptable object represents a spawnable object within the game and its properties for the purpose of loot tables in TNH and other stuff.

public class FVRObject : AnvilAsset
Inheritance
FVRObject
Inherited Members

Constructors

FVRObject()

public FVRObject()

Fields

BespokeAttachments

A list of attachments made specifically for this gun and won't work on any others.

public List<FVRObject> BespokeAttachments

Field Value

List<FVRObject>

Category

The category of this object

public FVRObject.ObjectCategory Category

Field Value

FVRObject.ObjectCategory

ClipType

FOR AMMO CLIPS ONLY: The type of this clip

public FireArmClipType ClipType

Field Value

FireArmClipType

CompatibleClips

FOR FIREARMS ONLY: The list of compatible ammo clips this gun can use. This is typically used in TNH when deciding what clips it can spawn with.

public List<FVRObject> CompatibleClips

Field Value

List<FVRObject>

CompatibleMagazines

FOR FIREARMS ONLY: The list of compatible magazines this gun can use. This is typically used in TNH when deciding what magazines it can spawn with.

public List<FVRObject> CompatibleMagazines

Field Value

List<FVRObject>

CompatibleSingleRounds

FOR FIREARMS ONLY: The list of compatible individual rounds of ammo this gun is compatible with. This is typically used in TNH when deciding what rounds it can spawn with.

public List<FVRObject> CompatibleSingleRounds

Field Value

List<FVRObject>

CompatibleSpeedLoaders

FOR FIREARMS ONLY: The list of compatible speed loaders this gun can use. This is typically used in TNH when deciding what speed loaders it can spawn with.

public List<FVRObject> CompatibleSpeedLoaders

Field Value

List<FVRObject>

CreditCost

The number of credits this object costs for the purpose of the M.E.A.T.S. gamemode

public int CreditCost

Field Value

int

DisplayName

The user-friendly name for this object. This is what gets shown to the user on the wrist menu when they are holding the object, for example.

public string DisplayName

Field Value

string

Family

The 'family' name this object belongs to. This is used in TNH object pools to limit the frequency of similar guns, such as the MP5s. Objects in the same family will combined receive the same probability in a pool as another object which has no family

public string Family

Field Value

string

IsModContent

True if this object has been loaded by a mod loader.

public bool IsModContent

Field Value

bool

ItemID

The internal ID of this object. This is used as the primary key in dictionaries and as the key used to serialize / deserialize this object.

public string ItemID

Field Value

string

MagazineCapacity

FOR MAGAZINE OBJECTS ONLY: the capacity of this magazine

public int MagazineCapacity

Field Value

int

MagazineType

FOR MAGAZINES ONLY: The type of this magazine

[SearchableEnum]
public FireArmMagazineType MagazineType

Field Value

FireArmMagazineType

Mass

The mass of this object. Possibly currently unused? No references found in dnSpy

public float Mass

Field Value

float

MaxCapacityRelated

The largest magazine capacity this gun is capable of having

public int MaxCapacityRelated

Field Value

int

MinCapacityRelated

The smallest magazine capacity this gun is capable of having

public int MinCapacityRelated

Field Value

int

OSple

Object Spawn Pool Loot Enabled. If false, this item is excluded from TNH loot pools.

public bool OSple

Field Value

bool

RequiredSecondaryPieces

A list of secondary objects that are required for this object to function.

public List<FVRObject> RequiredSecondaryPieces

Field Value

List<FVRObject>

RequiresPicatinnySight

FOR FIREARMS ONLY: if this firearm requires a picatinny sight to be spawned alongside it. Typically this is used for guns that have no built-in irons but do have a top rail.

public bool RequiresPicatinnySight

Field Value

bool

RoundType

FOR FIREARMS ONLY: The type of round this firearm fires

[SearchableEnum]
public FireArmRoundType RoundType

Field Value

FireArmRoundType

SpawnedFromId

The 'ItemID' field of the ItemSpawnerID that spawns this object. The ItemId from ItemSpawnerID does not need to match ItemID of this object

public string SpawnedFromId

Field Value

string

TagAttachmentFeature

FOR ATTACHMENTS ONLY: The type of this attachment

public FVRObject.OTagAttachmentFeature TagAttachmentFeature

Field Value

FVRObject.OTagAttachmentFeature

TagAttachmentMount

FOR ATTACHMENTS ONLY: The mount type this attaches to

public FVRObject.OTagFirearmMount TagAttachmentMount

Field Value

FVRObject.OTagFirearmMount

TagEra

FOR FIREARMS ONLY: The Era this firearm belongs in

public FVRObject.OTagEra TagEra

Field Value

FVRObject.OTagEra

TagFirearmAction

FOR FIREARMS ONLY: The action of this firearm

public FVRObject.OTagFirearmAction TagFirearmAction

Field Value

FVRObject.OTagFirearmAction

TagFirearmCountryOfOrigin

FOR FIREARMS ONLY: The country of origin of this firearm

[SearchableEnum]
public FVRObject.OTagFirearmCountryOfOrigin TagFirearmCountryOfOrigin

Field Value

FVRObject.OTagFirearmCountryOfOrigin

TagFirearmFeedOption

FOR FIREARMS ONLY: The feed modes this firearm supports

public List<FVRObject.OTagFirearmFeedOption> TagFirearmFeedOption

Field Value

List<FVRObject.OTagFirearmFeedOption>

TagFirearmFiringModes

FOR FIREARMS ONLY: The firing modes this firearm supports

public List<FVRObject.OTagFirearmFiringMode> TagFirearmFiringModes

Field Value

List<FVRObject.OTagFirearmFiringMode>

TagFirearmFirstYear

FOR FIREARMS ONLY: The year this firearm was introduced

public int TagFirearmFirstYear

Field Value

int

TagFirearmMounts

FOR FIREARMS ONLY: The mount types this firearm has

public List<FVRObject.OTagFirearmMount> TagFirearmMounts

Field Value

List<FVRObject.OTagFirearmMount>

TagFirearmRoundPower

FOR FIREARMS ONLY: The round power of this firearm

public FVRObject.OTagFirearmRoundPower TagFirearmRoundPower

Field Value

FVRObject.OTagFirearmRoundPower

TagFirearmSize

FOR FIREARMS ONLY: The size of this firearm

public FVRObject.OTagFirearmSize TagFirearmSize

Field Value

FVRObject.OTagFirearmSize

TagMeleeHandedness

FOR MELEE WEAPONS ONLY: The handedness of this weapon

public FVRObject.OTagMeleeHandedness TagMeleeHandedness

Field Value

FVRObject.OTagMeleeHandedness

TagMeleeStyle

FOR MELEE WEAPONS ONLY: The style of this weapon

public FVRObject.OTagMeleeStyle TagMeleeStyle

Field Value

FVRObject.OTagMeleeStyle

TagPowerupType

FOR POWERUPS ONLY: The type of this powerup

public FVRObject.OTagPowerupType TagPowerupType

Field Value

FVRObject.OTagPowerupType

TagSet

FOR FIREARMS ONLY: The set this firearm belongs in

public FVRObject.OTagSet TagSet

Field Value

FVRObject.OTagSet

TagThrownDamageType

FOR THROWN OBJECTS ONLY: The damage type this thrown object inflicts

public FVRObject.OTagThrownDamageType TagThrownDamageType

Field Value

FVRObject.OTagThrownDamageType

TagThrownType

FOR THROWN OBJECTS ONLY: The type of this thrown object

public FVRObject.OTagThrownType TagThrownType

Field Value

FVRObject.OTagThrownType

UsesRoundTypeFlag

FOR FIREARMS ONLY: Not really sure what this does

public bool UsesRoundTypeFlag

Field Value

bool

Methods

CalcCreditCost()

public void CalcCreditCost()

CheckMagType()

public void CheckMagType()

ConfigureClipMagSpeedLoader()

public void ConfigureClipMagSpeedLoader()

GenerateItemIDFromDisplayName()

public void GenerateItemIDFromDisplayName()

GetRandomAmmoObject(FVRObject, List<OTagEra>, int, int, List<OTagSet>)

public FVRObject GetRandomAmmoObject(FVRObject o, List<FVRObject.OTagEra> eras = null, int Min = -1, int Max = -1, List<FVRObject.OTagSet> sets = null)

Parameters

o FVRObject
eras List<FVRObject.OTagEra>
Min int
Max int
sets List<FVRObject.OTagSet>

Returns

FVRObject

MigrateFirearmDataToMagazine()

public void MigrateFirearmDataToMagazine()

PopulateAttachments()

public void PopulateAttachments()

PopulateFirearmMagClipAmmoData()

public void PopulateFirearmMagClipAmmoData()

PopulateMagazineType()

public void PopulateMagazineType()

PopulateMinMaxCapacity()

public void PopulateMinMaxCapacity()

PopulateRoundPower()

public void PopulateRoundPower()

PrintBespoke()

public void PrintBespoke()

PrintIfStanag()

public void PrintIfStanag()

SetNamesFromFileName()

public void SetNamesFromFileName()