Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

d_t_noeffect_area OK #30

Merged
merged 1 commit into from
Sep 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions config/SOUE01/rels/d_t_noeffect_areaNP/splits.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,6 @@ REL/executor.c:
REL/d/t/d_t_noeffect_area.cpp:
.text start:0x00000070 end:0x00000268
.ctors start:0x00000000 end:0x00000004
.rodata start:0x00000000 end:0x0000000C
.data start:0x00000000 end:0x00000084
.bss start:0x00000008 end:0x00000010
30 changes: 15 additions & 15 deletions config/SOUE01/rels/d_t_noeffect_areaNP/symbols.txt
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
_prolog = .text:0x00000000; // type:function size:0x2C scope:global
_epilog = .text:0x00000030; // type:function size:0x2C scope:global
_unresolved = .text:0x00000060; // type:function size:0x4 scope:global
fn_596_70 = .text:0x00000070; // type:function size:0x5C
fn_596_D0 = .text:0x000000D0; // type:function size:0x94
fn_596_170 = .text:0x00000170; // type:function size:0x34
fn_596_1B0 = .text:0x000001B0; // type:function size:0x8
fn_596_1C0 = .text:0x000001C0; // type:function size:0x8
fn_596_1D0 = .text:0x000001D0; // type:function size:0x10
fn_596_1E0 = .text:0x000001E0; // type:function size:0xC
fn_596_1F0 = .text:0x000001F0; // type:function size:0x5C
fn_596_250 = .text:0x00000250; // type:function size:0x18
dTgNoEffectArea_c_classInit__Fv = .text:0x00000070; // type:function size:0x5C
create__17dTgNoEffectArea_cFv = .text:0x000000D0; // type:function size:0x94
doDelete__17dTgNoEffectArea_cFv = .text:0x00000170; // type:function size:0x34
actorExecute__17dTgNoEffectArea_cFv = .text:0x000001B0; // type:function size:0x8
draw__17dTgNoEffectArea_cFv = .text:0x000001C0; // type:function size:0x8
addToList__17dTgNoEffectArea_cFR9fLiMgBa_c = .text:0x000001D0; // type:function size:0x10
getList__17dTgNoEffectArea_cFv = .text:0x000001E0; // type:function size:0xC
__dt__17dTgNoEffectArea_cFv = .text:0x000001F0; // type:function size:0x5C
__sinit_\d_t_noeffect_area_cpp = .text:0x00000250; // type:function size:0x18 scope:local
_ctors = .ctors:0x00000000; // type:label scope:global
_dtors = .dtors:0x00000000; // type:label scope:global
lbl_596_rodata_0 = .rodata:0x00000000; // type:object size:0x4
lbl_596_rodata_4 = .rodata:0x00000004; // type:object size:0x4
lbl_596_rodata_8 = .rodata:0x00000008; // type:object size:0x4 data:float
lbl_596_data_0 = .data:0x00000000; // type:object size:0x10
lbl_596_data_10 = .data:0x00000010; // type:object size:0x74
lbl_596_bss_8 = .bss:0x00000008; // type:object size:0x8 data:4byte
sFloat1__17dTgNoEffectArea_c = .rodata:0x00000000; // type:object size:0x4
sFloat2__17dTgNoEffectArea_c = .rodata:0x00000004; // type:object size:0x4
lbl_596_rodata_8 = .rodata:0x00000008; // type:object size:0x4 scope:local data:float
g_profile_TAG_NOEFFECT_AREA = .data:0x00000000; // type:object size:0x10
__vt__17dTgNoEffectArea_c = .data:0x00000010; // type:object size:0x74
sList__17dTgNoEffectArea_c = .bss:0x00000008; // type:object size:0x8 data:4byte
2 changes: 1 addition & 1 deletion configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -1151,7 +1151,7 @@ def nw4rLib(lib_name, objects, extra_cflags=[]):
Rel(NonMatching, "d_t_mole_prohibit", "REL/d/t/d_t_mole_prohibit.cpp"),
Rel(NonMatching, "d_t_musasabi", "REL/d/t/d_t_musasabi.cpp"),
Rel(NonMatching, "d_t_musou", "REL/d/t/d_t_musou.cpp"),
Rel(NonMatching, "d_t_noeffect_area", "REL/d/t/d_t_noeffect_area.cpp"),
Rel(Matching, "d_t_noeffect_area", "REL/d/t/d_t_noeffect_area.cpp"),
Rel(NonMatching, "d_t_player_restart", "REL/d/t/d_t_player_restart.cpp"),
Rel(NonMatching, "d_t_plight", "REL/d/t/d_t_plight.cpp"),
Rel(NonMatching, "d_t_pltchg", "REL/d/t/d_t_pltchg.cpp"),
Expand Down
31 changes: 31 additions & 0 deletions include/d/tg/d_t_noeffect_area.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#ifndef D_T_NOEFFECT_AREA_H
#define D_T_NOEFFECT_AREA_H

#include <d/tg/d_tg.h>
#include <f/f_list_mg.h>
#include <m/m_mtx.h>

class dTgNoEffectArea_c : public dTg_c {
public:
dTgNoEffectArea_c() : mEntry(this) {}
virtual ~dTgNoEffectArea_c() {}

virtual int create() override;
virtual int doDelete() override;
virtual int actorExecute() override;
virtual int draw() override;

static fLiNdBa_c *getList();

static const f32 sFloat1;
static const f32 sFloat2;

private:
void addToList(fLiMgBa_c &list);

static fLiMgBa_c sList;
fLiNdBa_c mEntry;
mMtx_c mMtx;
};

#endif
38 changes: 38 additions & 0 deletions src/REL/d/t/d_t_noeffect_area.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#include <d/tg/d_t_noeffect_area.h>

SPECIAL_ACTOR_PROFILE(TAG_NOEFFECT_AREA, dTgNoEffectArea_c, fProfile::TAG_NOEFFECT_AREA, 0x0158, 0, 0);

fLiMgBa_c dTgNoEffectArea_c::sList;

const f32 dTgNoEffectArea_c::sFloat1 = 100.0f;
const f32 dTgNoEffectArea_c::sFloat2 = 100.0f;

int dTgNoEffectArea_c::create() {
scale *= 0.01f;
PSMTXTrans(mMtx, position.x, position.y, position.z);
mMtx.YrotM(rotation.y);
PSMTXInverse(mMtx, mMtx);
addToList(sList);
return SUCCEEDED;
}

int dTgNoEffectArea_c::doDelete() {
sList.remove(&this->mEntry);
return 1;
}

int dTgNoEffectArea_c::actorExecute() {
return 1;
}

int dTgNoEffectArea_c::draw() {
return 1;
}

void dTgNoEffectArea_c::addToList(fLiMgBa_c &list) {
list.append(&this->mEntry);
}

fLiNdBa_c *dTgNoEffectArea_c::getList() {
return sList.getFirst();
}