isle-portable/LEGO1/lego/legoomni/include/legoplants.h
Christian Semmler 492954f347
Updates from isledecomp/isle (#27)
* Implement/match Bike (#1036)

* Implement/match Motocycle, consistent notification names (#1037)

* Implement/match Motocycle, consistent notification names

* Format

* Fix

* Fix return types

* Fix return type

* Fix annotations

* Rename function

* Bootstrap LegoPlantManager, add plants data (#1038)

* Bootstrap LegoPlantManager, add plants data

* Naming

* Move

* Fix

* Implement/match LegoPlantManager::CreatePlant (#1039)

* Implement/match LegoPlantManager::CreatePlant

* Update names

* Fix name

* Fix

* Fix

* Implement/match more LegoPlantManager functions (#1040)

* Implement/match LegoPlantManager interaction functions (#1041)

* Implement AnimState (#1042)

* Implement LegoAnim

* fix: minor issues

* fix ncc complaints

* refactor: address review comments

---------

Co-authored-by: jonschz <jonschz@users.noreply.github.com>

* Implement/match LegoPlantManager::FUN_10026c50 (#1043)

* Minor fixes

* Implement/match LegoPlantManager::FUN_10026c50

* Backports of isle-portable x64 fixes (#1044)

* Introduce LPD3DRM_APPDATA typedef for setting d3drm appdata

* Fix warning about assigning const string literals to variable char pointers

* Don't cast pointers to integers on non-32-bit architectures

* memset 2nd argument is int

* Assume cpuid is available on x86_64, needs testing on i386 and unavailable on anything else

* Store HFILE in its own member variable

* Updates

---------

Co-authored-by: jonschz <17198703+jonschz@users.noreply.github.com>
Co-authored-by: jonschz <jonschz@users.noreply.github.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
2024-06-25 18:12:08 +02:00

60 lines
1.4 KiB
C++

#ifndef LEGOPLANTS_H
#define LEGOPLANTS_H
#include "decomp.h"
#include "mxtypes.h"
class LegoEntity;
class LegoPathBoundary;
// SIZE 0x54
struct LegoPlantInfo {
// See LegoOmni::RegisterWorlds for IDs
enum World {
c_act1 = 1 << 0,
c_imain = 1 << 1,
c_ielev = 1 << 4,
c_iisle = 1 << 5,
c_act2 = 1 << 15,
c_act3 = 1 << 16
};
enum Variant {
e_flower = 0,
e_tree,
e_bush,
e_palm
};
enum Color {
e_white = 0,
e_black,
e_yellow,
e_red,
e_green
};
LegoEntity* m_entity; // 0x00
MxU32 m_worlds; // 0x04 - see enum for possible bit flags
MxU8 m_variant; // 0x08 - see enum for possible values
MxU32 m_sound; // 0x0c
MxU32 m_move; // 0x10
MxU8 m_mood; // 0x14
MxU8 m_color; // 0x15 - see enum for possible values
MxS8 m_unk0x16; // 0x16
MxS8 m_initialUnk0x16; // 0x17 - initial value loaded to m_unk0x16
const char* m_name; // 0x18
undefined4 m_unk0x1c; // 0x1c
float m_x; // 0x20
float m_y; // 0x24
float m_z; // 0x28
LegoPathBoundary* m_boundary; // 0x2c
float m_position[3]; // 0x30
float m_direction[3]; // 0x3c
float m_up[3]; // 0x48
};
extern LegoPlantInfo g_plantInfoInit[81];
#endif // LEGOPLANTS_H