Vagrant Story/actor data

From Data Crystal
< Vagrant Story
Revision as of 17:00, 27 October 2024 by Lelegofrog (talk | contribs) (Lelegofrog moved page Vagrant Story:actor data to Vagrant Story/actor data)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This is a sub-page of Vagrant Story.

Actor data struct contains information about additional characters that are currently present in the room with the player. Most of the time they are enemies, seldom friendly NPCs (like Sydney during the fight with Grissom). This struct is never used during the cut-scenes.

The pointer to the first actor is always located at the address 0x8011f9f0. If there's another actor in the room, the first 4 bytes of the struct contains its address; 0x0 otherwise. This way all the structs form a classic linked-list. If an actor is killed, the memory, that was allocated for its data, is freed (either right away, or as soon as it's looted), and the list is rearranged accordingly (all the pointers are updated).

$0	4	next Actor pointer
$4	40	_padding0
$2c	2	X coordinate
$2e	2	Y coordinate
$30	12	padding
$3c	4	Actor's Name pointer
$40	16	padding
$50	24	Actor's Name
$68	2	Current HP
$6a	2	Max HP
$6c	2	Current MP
$6e	2	Max MP
$70	2	RISK
$72	2s	Original STR
$74	2s	Equipped STR
$76	2s	Original INT
$78	2s	Equipped INT
$7a	2s	Original AGL
$7c	2s	Equipped AGL
$7e	14	padding
$8c	24	Weapon Name
$a4	48	Blade equip data
$d4	48	Grip equip data
$104	48	Weapon Gem 1 equip data
$134	48	Weapon Gem 2 equip data
$164	48	Weapon Gem 3 equip data
$194	168	padding
$23c	48	Shield equip data
$26c	48	Shield Gem 1 equip data
$29c	48	Shield Gem 2 equip data
$2cc	48	Shield Gem 3 equip data
$2fc	140	padding
$388	48	Accessory equip data
$3b8	80	padding
$408	48	Right Arm equip data
$438	172	padding
$4e4	48	Left Arm equip data
$514	172	padding
$5c0	48	Helm equip data
$5f0	172	padding
$69c	48	Breastplate equip data
$6cc	172	padding
$778	48	Leggings equip data
$7a8	496	padding
$998	16	Status effects
$9a8	2	Guaranteed misc loot item 1 name
$9aa	1	Guaranteed misc loot item 1 quantity
$9ab	1	padding
$9ac	2	Guaranteed misc loot item 2 name
$9ae	1	Guaranteed misc loot item 2 quantity
$9af	1	padding
$9b0	2	Misc loot name
$9b2	1	Misc loot item drop chance: range(0.0-1.0) * 255


This data struct layout is most likely incomplete. All the fields named "padding" can contain more useful data. Feel free to add your findings, or contact me via Müllenkamp Discord server.