Table of Contents

Class AvatarState

Namespace
Nekoyume.Model.State
Assembly
Lib9c.dll

Agent가 포함하는 각 Avatar의 상태 모델이다.

[Serializable]
public class AvatarState : State, IState, ICloneable
Inheritance
AvatarState
Implements
Inherited Members
Extension Methods

Constructors

AvatarState(Dictionary)

public AvatarState(Dictionary serialized)

Parameters

serialized Dictionary

AvatarState(List)

public AvatarState(List serialized)

Parameters

serialized List

AvatarState(Address, Address, long, QuestList, WorldInformation, Address, string)

public AvatarState(Address address, Address agentAddress, long blockIndex, QuestList questList, WorldInformation worldInformation, Address rankingMapAddress, string name = null)

Parameters

address Address
agentAddress Address
blockIndex long
questList QuestList
worldInformation WorldInformation
rankingMapAddress Address
name string

AvatarState(AvatarState)

public AvatarState(AvatarState avatarState)

Parameters

avatarState AvatarState

Fields

CombinationSlotCapacity

public const int CombinationSlotCapacity = 8

Field Value

int

CurrentVersion

public const int CurrentVersion = 2

Field Value

int

DefaultCombinationSlotCount

public const int DefaultCombinationSlotCount = 4

Field Value

int

RankingMapAddress

[Obsolete("don't use this field.")]
public readonly Address RankingMapAddress

Field Value

Address

actionPoint

public int actionPoint

Field Value

int

agentAddress

public Address agentAddress

Field Value

Address

blockIndex

public long blockIndex

Field Value

long

characterId

public int characterId

Field Value

int

combinationSlotAddresses

[Obsolete("don't use this field, use AllCombinationSlotState instead.")]
public List<Address> combinationSlotAddresses

Field Value

List<Address>

dailyRewardReceivedIndex

public long dailyRewardReceivedIndex

Field Value

long

ear

public int ear

Field Value

int

eventMap

public CollectionMap eventMap

Field Value

CollectionMap

exp

public long exp

Field Value

long

hair

public int hair

Field Value

int

inventory

public Inventory inventory

Field Value

Inventory

itemMap

public CollectionMap itemMap

Field Value

CollectionMap

lens

public int lens

Field Value

int

level

public int level

Field Value

int

mailBox

public MailBox mailBox

Field Value

MailBox

monsterMap

public CollectionMap monsterMap

Field Value

CollectionMap

name

public string name

Field Value

string

questList

public QuestList questList

Field Value

QuestList

stageMap

public CollectionMap stageMap

Field Value

CollectionMap

tail

public int tail

Field Value

int

updatedAt

public long updatedAt

Field Value

long

worldInformation

public WorldInformation worldInformation

Field Value

WorldInformation

Properties

NameWithHash

public string NameWithHash { get; }

Property Value

string

Nonce

public int Nonce { get; }

Property Value

int

Version

public int Version { get; }

Property Value

int

Methods

Apply(Player, long)

public void Apply(Player player, long index)

Parameters

player Player
index long

Clone()

Creates a new object that is a copy of the current instance.

public object Clone()

Returns

object

A new object that is a copy of this instance.

Create(Address, Address, long, AvatarSheets, Address, string)

public static AvatarState Create(Address address, Address agentAddress, long blockIndex, AvatarSheets avatarSheets, Address rankingMapAddress, string name = null)

Parameters

address Address
agentAddress Address
blockIndex long
avatarSheets AvatarSheets
rankingMapAddress Address
name string

Returns

AvatarState

CreateAvatarAddress()

public static Address CreateAvatarAddress()

Returns

Address

Customize(int, int, int, int)

public void Customize(int hair, int lens, int ear, int tail)

Parameters

hair int
lens int
ear int
tail int

EquipCostumes(HashSet<int>)

public void EquipCostumes(HashSet<int> costumeIds)

Parameters

costumeIds HashSet<int>

EquipEquipments(List<Guid>)

public void EquipEquipments(List<Guid> equipmentIds)

Parameters

equipmentIds List<Guid>

EquipItems(IEnumerable<Guid>)

public void EquipItems(IEnumerable<Guid> itemIds)

Parameters

itemIds IEnumerable<Guid>

GetArmorId()

public int GetArmorId()

Returns

int

GetNonFungibleItems<T>(List<Guid>)

public List<T> GetNonFungibleItems<T>(List<Guid> itemIds)

Parameters

itemIds List<Guid>

Returns

List<T>

Type Parameters

T

GetPortraitId()

public int GetPortraitId()

Returns

int

GetRandomSeed()

public int GetRandomSeed()

Returns

int

Serialize()

public override IValue Serialize()

Returns

IValue

SerializeList()

public IValue SerializeList()

Returns

IValue

Update(IStageSimulator)

public void Update(IStageSimulator stageSimulator)

Parameters

stageSimulator IStageSimulator

Update(Mail)

public void Update(Mail mail)

Parameters

mail Mail

Update2(Mail)

[Obsolete("Use Update")]
public void Update2(Mail mail)

Parameters

mail Mail

Update3(Mail)

[Obsolete("Use Update")]
public void Update3(Mail mail)

Parameters

mail Mail

UpdateFromAddCostume(Costume, bool)

public void UpdateFromAddCostume(Costume costume, bool canceled)

Parameters

costume Costume
canceled bool

UpdateFromAddItem(ItemBase, int, bool)

public void UpdateFromAddItem(ItemBase itemUsable, int count, bool canceled)

Parameters

itemUsable ItemBase
count int
canceled bool

UpdateFromAddItem(ItemUsable, bool)

public void UpdateFromAddItem(ItemUsable itemUsable, bool canceled)

Parameters

itemUsable ItemUsable
canceled bool

UpdateFromAddItem2(ItemBase, int, bool)

[Obsolete("Use UpdateFromAddItem")]
public void UpdateFromAddItem2(ItemBase itemUsable, int count, bool canceled)

Parameters

itemUsable ItemBase
count int
canceled bool

UpdateFromAddItem2(ItemUsable, bool)

[Obsolete("Use UpdateFromAddItem")]
public void UpdateFromAddItem2(ItemUsable itemUsable, bool canceled)

Parameters

itemUsable ItemUsable
canceled bool

UpdateFromCombination(ItemUsable)

public void UpdateFromCombination(ItemUsable itemUsable)

Parameters

itemUsable ItemUsable

UpdateFromCombination2(ItemUsable)

public void UpdateFromCombination2(ItemUsable itemUsable)

Parameters

itemUsable ItemUsable

UpdateFromItemEnhancement(Equipment)

public void UpdateFromItemEnhancement(Equipment equipment)

Parameters

equipment Equipment

UpdateFromItemEnhancement2(Equipment)

public void UpdateFromItemEnhancement2(Equipment equipment)

Parameters

equipment Equipment

UpdateFromQuestReward(Quest, MaterialItemSheet)

public void UpdateFromQuestReward(Quest quest, MaterialItemSheet materialItemSheet)

Parameters

quest Quest
materialItemSheet MaterialItemSheet

UpdateFromQuestReward2(Quest, MaterialItemSheet)

[Obsolete("Use UpdateFromQuestReward")]
public void UpdateFromQuestReward2(Quest quest, MaterialItemSheet materialItemSheet)

Parameters

quest Quest
materialItemSheet MaterialItemSheet

UpdateFromRapidCombination(ResultModel, long)

public void UpdateFromRapidCombination(CombinationConsumable5.ResultModel result, long requiredIndex)

Parameters

result CombinationConsumable5.ResultModel
requiredIndex long

UpdateFromRapidCombinationV2(ResultModel, long)

public void UpdateFromRapidCombinationV2(RapidCombination5.ResultModel result, long requiredIndex)

Parameters

result RapidCombination5.ResultModel
requiredIndex long

UpdateGeneralQuest(IEnumerable<QuestEventType>)

public void UpdateGeneralQuest(IEnumerable<QuestEventType> types)

Parameters

types IEnumerable<QuestEventType>

UpdateQuestRewards(MaterialItemSheet)

public void UpdateQuestRewards(MaterialItemSheet materialItemSheet)

Parameters

materialItemSheet MaterialItemSheet

UpdateQuestRewards2(MaterialItemSheet)

[Obsolete("Use UpdateQuestRewards")]
public void UpdateQuestRewards2(MaterialItemSheet materialItemSheet)

Parameters

materialItemSheet MaterialItemSheet

UpdateTemp(Mail, long)

[Obsolete("No longer in use.")]
public void UpdateTemp(Mail mail, long currentBlockIndex)

Parameters

mail Mail
currentBlockIndex long

ValidateConsumable(List<Guid>, long)

public List<int> ValidateConsumable(List<Guid> consumableIds, long currentBlockIndex)

Parameters

consumableIds List<Guid>
currentBlockIndex long

Returns

List<int>

ValidateConsumableV2(List<Guid>, long, GameConfigState)

public List<int> ValidateConsumableV2(List<Guid> consumableIds, long currentBlockIndex, GameConfigState gameConfigState)

Parameters

consumableIds List<Guid>
currentBlockIndex long
gameConfigState GameConfigState

Returns

List<int>

ValidateCostume(HashSet<int>)

public void ValidateCostume(HashSet<int> costumeIds)

Parameters

costumeIds HashSet<int>

ValidateCostume(IEnumerable<Guid>)

public List<int> ValidateCostume(IEnumerable<Guid> costumeIds)

Parameters

costumeIds IEnumerable<Guid>

Returns

List<int>

ValidateCostumeV2(IEnumerable<Guid>, GameConfigState)

public List<Costume> ValidateCostumeV2(IEnumerable<Guid> costumeIds, GameConfigState gameConfigState)

Parameters

costumeIds IEnumerable<Guid>
gameConfigState GameConfigState

Returns

List<Costume>

ValidateEquipments(List<Guid>, long)

public void ValidateEquipments(List<Guid> equipmentIds, long blockIndex)

Parameters

equipmentIds List<Guid>
blockIndex long

ValidateEquipmentsV2(List<Guid>, long)

public List<Equipment> ValidateEquipmentsV2(List<Guid> equipmentIds, long blockIndex)

Parameters

equipmentIds List<Guid>
blockIndex long

Returns

List<Equipment>

ValidateEquipmentsV3(List<Guid>, long, GameConfigState)

public List<Equipment> ValidateEquipmentsV3(List<Guid> equipmentIds, long blockIndex, GameConfigState gameConfigState)

Parameters

equipmentIds List<Guid>
blockIndex long
gameConfigState GameConfigState

Returns

List<Equipment>

ValidateItemRequirement(List<int>, List<Equipment>, ItemRequirementSheet, EquipmentItemRecipeSheet, EquipmentItemSubRecipeSheetV2, EquipmentItemOptionSheet, string)

public void ValidateItemRequirement(List<int> itemIds, List<Equipment> equipments, ItemRequirementSheet requirementSheet, EquipmentItemRecipeSheet recipeSheet, EquipmentItemSubRecipeSheetV2 subRecipeSheet, EquipmentItemOptionSheet itemOptionSheet, string addressesHex)

Parameters

itemIds List<int>
equipments List<Equipment>
requirementSheet ItemRequirementSheet
recipeSheet EquipmentItemRecipeSheet
subRecipeSheet EquipmentItemSubRecipeSheetV2
itemOptionSheet EquipmentItemOptionSheet
addressesHex string