Documentation
¶
Index ¶
- Constants
- func GetBestSN(category, gender, idx int) int32
- func GetCommodities() map[int32]Commodity
- func GetCommoditySNByItemID(itemID int32) (int32, bool)
- func GetMaps() map[int32]Map
- func GetMobSkills(id int32) map[byte]byte
- func GetPackages() map[int32][]int32
- func GetQuests() map[int16]Quest
- func GetReactorInfoList() map[int32]ReactorInfo
- func LoadFile(fname string)
- type ActBlock
- type ActItem
- type CheckBlock
- type Commodity
- type FeaturedKey
- type Foothold
- type Item
- type Life
- type Map
- type Mob
- type MobSkill
- type NXVec2
- type PetReaction
- type PlayerSkill
- type Portal
- type Quest
- type QuestStateReq
- type Reactor
- type ReactorEventInfo
- type ReactorInfo
- type ReactorStateInfo
- type ReqItem
- type ReqMob
Constants ¶
View Source
const ( StockStateDefault = 0 // available StockStateNotAvailable = 1 )
StockState values mirrored for client
Variables ¶
This section is empty.
Functions ¶
func GetCommodities ¶
GetCommodities returns the global commodity map keyed by SN.
func GetCommoditySNByItemID ¶
func GetPackages ¶
func GetReactorInfoList ¶
func GetReactorInfoList() map[int32]ReactorInfo
GetReactorInfoList from loaded nx
Types ¶
type CheckBlock ¶
type Commodity ¶
type Commodity struct {
Index int32 // numeric key under Commodity.img
// NX fields
SN int32
ItemID int32
Count int32
Gender int32
Period int32
OnSale int32
Price int32
Priority int32
Class int32 // optional
// Derived
Category int32 // floor(SN/10_000_000)+1
StockState int32 // computed at load time
}
Commodity mirrors /Etc/Commodity.img/<index>/
func GetCommodity ¶
GetCommodity returns a single commodity by SN.
type FeaturedKey ¶
type Item ¶
type Item struct {
InvTabID byte
Name string
Cash, Pet bool
Only, TradeBlock, ExpireOnLogout, Quest, TimeLimited int64
ReqLevel byte
Tuc byte // Total upgrade count?
SlotMax int16
ReqJob int64
ReqSTR, ReqDEX, ReqINT, ReqLUK, IncSTR, IncDEX, IncINT, IncLUK int16
IncACC, IncEVA, IncMDD, IncPDD, IncMAD, IncPAD, IncMHP, IncMMP float64
Speed, Jump, PAD, PDD, MAD, MDD, ACC, EVA int16
Poison, Darkness, Weakness, Curse, Seal int16
Attack, IncJump, IncSpeed, RecoveryHP float64
HP, MP int16
Time int16
AttackSpeed int16
Price int32
NotSale int64
UnitPrice float64
Life, Hungry int64
PickupItem, PickupAll, SweepForDrop int64
ConsumeHP, LongRange int64
Recovery float64
ReqPOP int64 // ?
NameTag int64
Pachinko int64
VSlot, ISlot string
Type int64
Success int64 // Scroll type
Cursed int64
Add int64 // ?
DropSweep int64
Rate int64
Meso int64
Path string
FloatType int64
NoFlip string
StateChangeItem int64
BigSize int64
Sfx string
Walk int64
AfterImage string
Stand int64
Knockback int64
Fs int64
ChatBalloon int64
MoveTo int32
Interact map[byte]PetReaction
SpawnMobs map[int32]int32
}
Item data from nx
type Life ¶
type Life struct {
ID int32
Type string
Foothold int16
FaceLeft bool
X, Y int16
MobTime int64
Hide int64
Rx0, Rx1 int16
Cy int64
Info int64
}
Life object in a map
type Map ¶
type Map struct {
Town bool
ForcedReturn int64
ReturnMap int32
MobRate float64
Swim, PersonalShop, EntrustedShop, ScrollDisable int64
MoveLimit int64
DecHP int64
NPCs []Life
Mobs []Life
Portals []Portal
Reactors []Reactor
Footholds []Foothold
FieldLimit int64
VRRight, VRTop, VRLeft, VRBottom, VRLimit int64
Recovery float64
Version int64
Bgm, MapMark string
Cloud, HideMinimap int64
MapDesc, Effect string
Fs float64
TimeLimit int64
FieldType int64
Everlast, Snow, Rain int64
MapName, StreetName, Help string
}
Map data from nx
type Mob ¶
type Mob struct {
HP, MP int32 // Not in nx
MaxHP, HPRecovery int32
MaxMP, MPRecovery int32
Level int64
Exp int64
MADamage, MDDamage int64
PADamage, PDDamage int64
Speed, Eva, Acc int64
SummonType int8
SummonOption int32
Boss, Undead int64
ElemAttr string
Link int64
FlySpeed int64
NoRegen int64
Invincible int64
SelfDestruction int64
ExplosiveReward int64
Skills map[byte]byte
Revives []int32
Fs float64
Pushed int64
BodyAttack int64
NoFlip int64
NotAttack int64
FirstAttack int64
RemoveQuest int64
RemoveAfter string
PublicReward int64
HPTagBGColor int64
HPTagColor int64
}
Mob data from nx
type MobSkill ¶
type MobSkill struct {
Hp int32
MpCon int32
Limit, Interval int64
MobID []int64
SummonEffect int64
Time int64
}
MobSkill data from nx
type PlayerSkill ¶
type PlayerSkill struct {
Mastery int64
Mad, Mdd, Pad, Pdd int64
Hp, Mp, HpCon, MpCon int64
BulletConsume int64
MoneyConsume int64
ItemCon int64
ItemConNo int64
Time int64
Cooltime int64
Eva, Acc, Jump, Speed int64
Range int64
MobCount int64
AttackCount int64
Damage int64
Fixdamage int64
Rb, Lt gonx.Vector
Hs string
X, Y, Z int64
Prop int64
BulletCount int64
Action string
}
PlayerSkill data from nx
func GetPlayerSkill ¶
func GetPlayerSkill(id int32) ([]PlayerSkill, error)
GetPlayerSkill from loaded nx
type Quest ¶
type Quest struct {
ID int16
Name string
Parent string
Order int16
Area int32
Journal map[int]string
// Requirements
Start CheckBlock // from Check[questID]["0"]
Complete CheckBlock // from Check[questID]["1"]
// Actions / rewards
ActOnStart ActBlock // from Act[questID]["0"]
ActOnComplete ActBlock // from Act[questID]["1"]
// Keys like: "start.0","start.1","complete.0","start.yes.0", etc.
Say map[string][]string
}
Quest data
type QuestStateReq ¶
type ReactorEventInfo ¶
type ReactorEventInfo struct {
Type int32
State int32
ReqItemID int32 // int name "0"
ReqItemCnt int32 // int name "1"
Probability int32 // int name "2"
LT NXVec2
RB NXVec2
ExtraInts map[string]int32
ExtraVecs map[string]NXVec2
}
ReactorEventInfo represents a single event entry under a reactor state's "event" node.
type ReactorInfo ¶
type ReactorInfo struct {
ID int32
Info string // /Reactor/<id>.img/info/info
Action string // /Reactor/<id>.img/action
States map[int]ReactorStateInfo
LinkTo int32 // /Reactor/<id>.img/info/link -> other reactor id
}
ReactorInfo is the reactor data for a single ID.
func GetReactorInfo ¶
func GetReactorInfo(id int32) (ReactorInfo, error)
GetReactorInfo from loaded nx
type ReactorStateInfo ¶
type ReactorStateInfo struct {
Events []ReactorEventInfo
}
ReactorStateInfo is a reactor state (e.g., "0", "1") and its events.
Click to show internal directories.
Click to hide internal directories.