Skip to content
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
45 changes: 37 additions & 8 deletions src/SB/Game/zThrown.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,43 @@

#include "xMathInlines.h"

zThrownStruct zThrownList[32];
LaunchStats l_normal;
ThrowableStats zThrowableModels[23];
U32 zThrownCount;
U32 sFruitIsFreezy;
U32 sDebugDepth;
CarryableStats c_fruit;
U32 sThrowButtonMask;
static zThrownStruct zThrownList[32];
static U32 zThrownCount;
static U32 sThrowButtonMask;
static F32 sSNDLandTimer;
static U32 sFruitIsFreezy;
static U32 sDebugDepth;

static LaunchStats l_normal = {10.0f, 15.0f, 0.2f};
static CarryableStats c_normal = {};
static CarryableStats c_fruit = {24.0f};

static ThrowableStats zThrowableModels[23] = {
{"__default__", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"tiki_wooden", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"reallybigrock", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_a", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_b", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_c", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_d", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_e", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"b3_roof_chunk_sm_f", zThrownCollide_DestructObj, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"tiki_wooden_bind", zThrownCollide_Tiki, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"tiki_thunder_bind", zThrownCollide_Tiki, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{"tiki_stone_bind", zThrownCollide_StoneTiki, &c_normal, &l_normal,{}, NULL, 0.0f, 0x0, 0x0, NULL},
{"fruit_freezy", zThrownCollide_ThrowFreeze, &c_fruit, &l_normal, {}, "fruit_freezy_shrapnel", 0.77f, 0x0, 0x0, NULL},
{"fruit_freezy_bind", zThrownCollide_ThrowFreeze, &c_fruit, &l_normal, {}, "fruit_freezy_shrapnel", 0.77f, 0x0, 0x0, NULL},
{"fruit_glow_blue", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {32, 32, 128, 255}, NULL, 0.92f, 0x0, 0x0, NULL},
{"fruit_glow_green", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {32, 128, 32, 255}, NULL, 0.92f, 0x0, 0x0, NULL},
{"fruit_glow_orange", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {128, 96, 32, 255}, NULL, 0.92f, 0x0, 0x0, NULL},
{"fruit_glow_red", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {128, 32, 32, 255}, NULL, 0.92f, 0x0, 0x0, NULL},
{"fruit_glow_yellow", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {128, 128, 32, 255}, NULL, 0.92f, 0x0, 0x0, NULL},
{"fruit_throw", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {32, 32, 32, 255}, "fruit_throw_shrapnel", 0.92f, 0x0, 0x0, NULL},
{"fruit_throw_bind", zThrownCollide_ThrowFruit, &c_fruit, &l_normal, {32, 32, 32, 255}, "fruit_throw_shrapnel", 0.92f, 0x0, 0x0, NULL},
{"boss_sa_head_bind", zThrownCollide_BSandyHead, &c_normal, &l_normal, {}, NULL, 0.0f, 0x0, 0x0, NULL},
{},
};


void zThrown_Setup(zScene* sc)
{
Expand Down
1 change: 1 addition & 0 deletions src/SB/Game/zThrown.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ void zThrownCollide_DestructObj(zThrownStruct* thrown, xEntCollis* collis, F32*
void zThrownCollide_BSandyHead(zThrownStruct* thrown, xEntCollis* collis, F32* bounce,
F32* friction);
void zThrownCollide_Tiki(zThrownStruct* thrown, xEntCollis* collis, F32* bounce, F32* friction);
void zThrownCollide_StoneTiki(class zThrownStruct *, class xEntCollis *, float *, float *);
void zThrown_AddFruit(xEnt* ent);
S32 zThrown_IsFruit(xEnt* ent, F32* stackHeight);
S32 zThrown_IsStacked(xEnt* ent);
Expand Down
Loading