diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/effects.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/effects.cpp b/src/effects.cpp index 8d0e565..40f08a2 100644 --- a/src/effects.cpp +++ b/src/effects.cpp @@ -1004,7 +1004,7 @@ const char* effects_name_list [] = { "Wm_ob_treasureboxwait_b" }; -extern "C" void SpawnEffect(const char*, int, Vec*, int, int); +extern "C" bool SpawnEffect(const char*, int, Vec*, S16Vec*, Vec*); // Just call CreateEffect(this, number_between_0_and_1000); bool CreateEffect(dEn_c* enemy, int effect_num) { @@ -1022,7 +1022,7 @@ bool CreateEffect(Vec* pos, S16Vec* rot, Vec* scale, int effect_num) { return false; if (effect_num < 0) return false; - Vec tempVec = (Vec){ pos.x, pos.y, 5500.0 }; + Vec tempVec = (Vec){ pos->x, pos->y, 5500.0 }; const char* effect_name = effects_name_list[effect_num]; return SpawnEffect(effect_name, 0, &tempVec, rot, scale); } @@ -1030,8 +1030,8 @@ bool CreateEffect(Vec* pos, S16Vec* rot, Vec* scale, int effect_num) { bool CreateEffect(const char* name, Vec* pos) { //check effects name list bool exists = false; - for( int ii = 0; ii < sizeof(effect_name_list); ii++) { - if (strncmp(name, effects_name_list[ii], strlen(effects_name_list) ) ) { + for( int ii = 0; ii < sizeof(effects_name_list); ii++) { + if (memcmp(name, effects_name_list[ii], strlen(effects_name_list[ii]) ) ) { exists = true; break; } |