add effects.h

This commit is contained in:
theo3
2021-10-26 20:33:33 -07:00
parent 3f5449c1a1
commit d29468c30b
67 changed files with 297 additions and 113 deletions
+2 -1
View File
@@ -9,6 +9,7 @@
#include "npc.h"
#include "audio.h"
#include "functions.h"
#include "effects.h"
extern void (*gUnk_081115C0[])(Entity*);
extern void (*gUnk_081115D0[])(Entity*);
@@ -165,7 +166,7 @@ void sub_08068BD0(Entity* this) {
void sub_08068BEC(Entity* this, u32 unused) {
Entity* target;
target = CreateFx(this, 0x44, 0);
target = CreateFx(this, FX_WHITE_SPLASH, 0);
if (target) {
target->spritePriority.b0 = 1;
PositionRelative(this, target, 0, -0x100000);
+2 -1
View File
@@ -2,6 +2,7 @@
#include "script.h"
#include "functions.h"
#include "flags.h"
#include "effects.h"
extern Hitbox gUnk_08110E94;
@@ -87,7 +88,7 @@ void sub_08067534(Entity* this) {
Entity* entity;
s32 i;
for (i = 0; i < 2; ++i) {
entity = CreateFx(this, 2, 0);
entity = CreateFx(this, FX_DEATH, 0);
if (entity != NULL) {
entity->x.HALF.HI += gUnk_08110E64[i];
entity->y.HALF.HI += 0x1c;
+2 -1
View File
@@ -3,6 +3,7 @@
#include "script.h"
#include "audio.h"
#include "functions.h"
#include "effects.h"
const u8 gUnk_08114134[];
const u8 gUnk_08114144[];
@@ -55,7 +56,7 @@ void sub_0806D944(Entity* this) {
// Ezlo Angry FX
void sub_0806D96C(Entity* this) {
Entity* fx = CreateFx(this, 0x42, 0);
Entity* fx = CreateFx(this, FX_STEAM_EFC, 0);
if (fx != NULL) {
fx->spritePriority.b0 = 1;
PositionRelative(this, fx, 0, 0xFFE80000);
+3 -2
View File
@@ -3,6 +3,7 @@
#include "functions.h"
#include "textbox.h"
#include "script.h"
#include "effects.h"
extern void (*gUnk_08111A80[])(Entity*);
extern void (*gUnk_08111A8C[])(Entity*);
@@ -79,13 +80,13 @@ void sub_080693D0(Entity* this) {
}
void sub_08069428(Entity* this, s32 offsetX, bool32 createFx65) {
Entity* fx = CreateFx(this, 4, 0);
Entity* fx = CreateFx(this, FX_ROCK, 0);
if (fx) {
PositionRelative(this, fx, offsetX, 0xFFF00000);
ResolveEntityOnTop(this, fx);
}
if (createFx65 != 0) {
fx = CreateFx(this, 65, 0);
fx = CreateFx(this, FX_REFLECT4, 0);
if (fx) {
PositionRelative(this, fx, offsetX, 0xFFF00000);
ResolveEntityOnTop(this, fx);
+2 -1
View File
@@ -2,6 +2,7 @@
#include "entity.h"
#include "textbox.h"
#include "functions.h"
#include "effects.h"
extern void sub_08063280();
@@ -58,5 +59,5 @@ void sub_08063280(Entity* this, u32 unused) {
var = e->frames.all & 0x7F;
e->frames.all ^= var;
if (var == 2)
CreateFx(e, 49, 0);
CreateFx(e, FX_MAILBOX_UNUSED, 0);
}
+2 -1
View File
@@ -6,6 +6,7 @@
#include "random.h"
#include "audio.h"
#include "functions.h"
#include "effects.h"
extern void sub_08068780(Entity*);
extern s32 sub_0806EDD8(Entity*, u32, u32);
@@ -91,7 +92,7 @@ void sub_08068780(Entity* this) {
} else {
EnqueueSFX(gUnk_08111538[(s32)Random() % 3]);
}
ent = CreateFx(this, 0x3d, 0x20);
ent = CreateFx(this, FX_STARS2, 0x20);
if (ent != NULL) {
PositionRelative(this, ent, 0x180000, -0xa0000);
}
+2 -1
View File
@@ -6,6 +6,7 @@
#include "flags.h"
#include "script.h"
#include "save.h"
#include "effects.h"
extern void sub_0806B41C(Entity*);
extern void sub_0806B3CC(Entity*);
@@ -63,7 +64,7 @@ void sub_0806B41C(Entity* this) {
this->action = 1;
this->spriteSettings.b.draw = 1;
if (this->type2 == 2) {
CreateFx(this, 0x25, 0);
CreateFx(this, FX_SWEAT, 0);
}
sub_0807DD50(this);
}
+2 -1
View File
@@ -9,6 +9,7 @@
#include "save.h"
#include "script.h"
#include "flags.h"
#include "effects.h"
extern void sub_08060528(Entity*);
extern void sub_0806EE04(Entity*, void*, u32);
@@ -99,7 +100,7 @@ void sub_080604DC(Entity* this) {
if (((u32)(this->spriteSettings.raw << 0x1e) >> 0x1e == 1) && sub_080040A8(this)) {
if ((this->frames.all & 1) != 0) {
this->frames.all &= 0xfe;
ent = CreateFx(this, 0x11, 0x40);
ent = CreateFx(this, FX_DASH, 0x40);
if (ent != NULL) {
ent->y.HALF.HI++;
sub_0805E3A0(ent, 3);
+2 -1
View File
@@ -7,6 +7,7 @@
#include "npc.h"
#include "audio.h"
#include "functions.h"
#include "effects.h"
extern void sub_08078850(Entity*, u32, u32, u32*);
@@ -43,7 +44,7 @@ void Smith(Entity* this) {
}
if ((this->frames.all & 1) != 0) {
this->frames.all &= 0xfe;
CreateFx(this, 0x3d, 0x20);
CreateFx(this, FX_STARS2, 0x20);
SoundReq(gUnk_08110380[(Random() & 7)]);
}
}
+2 -1
View File
@@ -3,6 +3,7 @@
#include "textbox.h"
#include "functions.h"
#include "script.h"
#include "effects.h"
extern void sub_08062CA4();
@@ -57,7 +58,7 @@ void sub_08062C7C(Entity* ent) {
ent->action = 1;
sub_0807DD64(ent);
InitializeAnimation(ent, 0);
CreateFx(ent, 37, 0);
CreateFx(ent, FX_SWEAT, 0);
sub_08062CA4(ent);
}
+2 -1
View File
@@ -9,6 +9,7 @@
#include "random.h"
#include "structures.h"
#include "functions.h"
#include "effects.h"
typedef struct {
u8 frame1;
@@ -228,7 +229,7 @@ void sub_08061E90(Entity* this, Entity* arg1) {
void sub_08061F94(Entity* this) {
Entity* ent;
ent = CreateFx(this, 0x35, 0);
ent = CreateFx(this, FX_BIG_EXPLOSION, 0);
if (ent != NULL) {
ResolveEntityOnTop(this, ent);
}