Skip to content

Commit

Permalink
tremulous: fix the bucket system for QVMs.
Browse files Browse the repository at this point in the history
  • Loading branch information
dGr8LookinSparky committed Mar 31, 2020
1 parent 89ea9ea commit 798ad46
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/filesystem/fs_tremulous.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ struct core_resource_s {

#define CORE_RESOURCES_1_3 \
{0, "core_game_dll"}, /* Core dll defined by FS_CORE_GAME_DLL_NAME */ \
1246283756, /* trem13/vms-gpp-v1.3.0-alpha.0.14.11.pk3 */ \
-1758827386 /* trem13/data-v1.3.0-alpha.0.14.11.pk3 */ \
-15297494, /* trem13/vms-gpp-v1.3.0-alpha.0.14.11.pk3 */ \
-1117796085 /* trem13/data-v1.3.0-alpha.0.14.11.pk3 */ \

#define CORE_RESOURCES_GPP \
-1154612609, /* gpp/vms-gpp1.pk3 */ \
Expand Down
2 changes: 1 addition & 1 deletion src/game/bg_misc.c
Original file line number Diff line number Diff line change
Expand Up @@ -4004,7 +4004,7 @@ void BG_Bucket_Remove_Item_From_Bucket(
}

void* BG_Bucket_Select_A_Random_Item(unsigned int bucket_handle) {
Q_Bucket_Select_A_Random_Item(bucket_handle);
return Q_Bucket_Select_A_Random_Item(bucket_handle);
}

void BG_Bucket_Select_A_Specific_Item(unsigned int bucket_handle, void* item) {
Expand Down
2 changes: 1 addition & 1 deletion src/qcommon/common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3935,7 +3935,7 @@ void Com_Bucket_Remove_Item_From_Bucket(
}

void* Com_Bucket_Select_A_Random_Item(unsigned int bucket_handle) {
Q_Bucket_Select_A_Random_Item(bucket_handle);
return Q_Bucket_Select_A_Random_Item(bucket_handle);
}

void Com_Bucket_Select_A_Specific_Item(unsigned int bucket_handle, void* item) {
Expand Down
2 changes: 1 addition & 1 deletion src/sdl/sdl_glimp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ static void GLimp_DetectAvailableModes(void)
return;
}

modes = (SDL_Rect*)SDL_calloc( (size_t)numSDLModes, sizeof( SDL_Rect ) );
modes = (SDL_Rect*)SDL_calloc( (size_t)numSDLModes + 1, sizeof( SDL_Rect ) );
if ( !modes )
{
ri.Error( ERR_FATAL, "Out of memory" );
Expand Down
2 changes: 1 addition & 1 deletion src/ui/ui_shared.c
Original file line number Diff line number Diff line change
Expand Up @@ -1943,7 +1943,7 @@ void Script_playLoopedBucket(itemDef_t *item, char **args)
DC->setCVar(selected_list_cvar, selected_list_cvar_string);
}

if(val) {
if(val[0] != '\0') {
strcpy(play_looped_sound_path, va("%s/%s", sound_bucket_directory, val));
DC->stopBackgroundTrack();
DC->startBackgroundTrack(play_looped_sound_path, play_looped_sound_path);
Expand Down

0 comments on commit 798ad46

Please sign in to comment.