Skip to content

Commit

Permalink
Freakloader is FREAKTURE COMPLETE, plus finished Kranion phase 1 music
Browse files Browse the repository at this point in the history
and crash fixes

What would you do if John "Scruffy" Super Freaks drank ALL of your Dr.
Pepper and called you a fuckhead? Would that be sick and twisted or
what?
  • Loading branch information
defnotreal committed Oct 5, 2023
1 parent f5dee89 commit fb8a142
Show file tree
Hide file tree
Showing 20 changed files with 47 additions and 56 deletions.
17 changes: 9 additions & 8 deletions Super Freaks 1 Ultimate Edition.yyp

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 0 additions & 17 deletions datafiles/chars/example/char.json

This file was deleted.

Binary file removed datafiles/chars/example/snd/death.ogg
Binary file not shown.
Binary file removed datafiles/chars/example/spr/death.png
Binary file not shown.
Binary file removed datafiles/chars/example/spr/hud.png
Binary file not shown.
Binary file removed datafiles/chars/example/spr/jump.png
Binary file not shown.
Binary file removed datafiles/chars/example/spr/mugshot.png
Binary file not shown.
Binary file removed datafiles/chars/example/spr/stand.png
Binary file not shown.
Binary file removed datafiles/chars/example/spr/walk.png
Binary file not shown.
2 changes: 1 addition & 1 deletion objects/obj_boss_geyzer/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ attack_y = undefined;
can_despawn = false;
blink = false;

character_index = character_indexes.geyzer;
character_index = global.character_indexes.geyzer;
2 changes: 1 addition & 1 deletion objects/obj_boss_negativequincy/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ wait = 0;
ground_on = false;
can_despawn = false;

character_index = character_indexes.negative_quincy;
character_index = global.character_indexes.negative_quincy;
2 changes: 1 addition & 1 deletion objects/obj_boss_superior/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ wait = 0;
attack_angle = 0;
can_despawn = false;

character_index = character_indexes.superior;
character_index = global.character_indexes.superior;
2 changes: 1 addition & 1 deletion objects/obj_boss_trashcanman/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ attack_x = x;
attack_y = y;
can_despawn = false;

character_index = character_indexes.trash_can_man;
character_index = global.character_indexes.trash_can_man;
8 changes: 4 additions & 4 deletions objects/obj_character_select/Other_10.gml
Original file line number Diff line number Diff line change
Expand Up @@ -193,14 +193,14 @@ switch (state)
{
global.player_list[_player_num][player_data.character_index]++;

if (global.player_list[_player_num][player_data.character_index] >= global.character_indexes.count)
if (global.player_list[_player_num][player_data.character_index] >= global.character_count)
global.player_list[_player_num][player_data.character_index] = 0;

while (global.characters_unlocked[global.player_list[_player_num][player_data.character_index]] == false)
{
global.player_list[_player_num][player_data.character_index]++;

if (global.player_list[_player_num][player_data.character_index] >= global.character_indexes.count)
if (global.player_list[_player_num][player_data.character_index] >= global.character_count)
global.player_list[_player_num][player_data.character_index] = 0;
}
}
Expand All @@ -209,13 +209,13 @@ switch (state)
global.player_list[_player_num][player_data.character_index]--;

if (global.player_list[_player_num][player_data.character_index] < 0)
global.player_list[_player_num][player_data.character_index] = global.character_indexes.count - 1;
global.player_list[_player_num][player_data.character_index] = global.character_count - 1;

while (global.characters_unlocked[global.player_list[_player_num][player_data.character_index]] == false)
{
global.player_list[_player_num][player_data.character_index]--;
if (global.player_list[_player_num][player_data.character_index] < 0)
global.player_list[_player_num][player_data.character_index] = global.character_indexes.count - 1;
global.player_list[_player_num][player_data.character_index] = global.character_count - 1;
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion objects/obj_credits/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ text = "SUPER FREAKS 1 ULTIMATE EDITION"
+ "\nmade with Aseprite"
+ "\nThe Creation of Freaky Freak HD Painting by EngineerKappa"
+ "\nEdibles Provider: Metalefactor"
+ "\nFreakLoader Custom Character Loader by defnotreal_"
+ "\nFreakloader Custom Character Loader by defnotreal_"
+ "\n"
+ "\nCHARACTERS BY:"
+ "\nSuperFreaksDev"
Expand Down
2 changes: 1 addition & 1 deletion objects/obj_manager/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,4 @@ gc_timer = 0;
gc_enable(false);
depth = -10005;

//show_debug_overlay(true);
//show_debug_overlay(true);
37 changes: 21 additions & 16 deletions scripts/scr_freakloader/scr_freakloader.gml
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,21 @@ function freakloader_init()
file_find_close();
}

global.character_indexes.count = array_length(struct_get_names(global.character_indexes)) + array_length(struct_get_names(global.custom_character_indexes));
global.character_count = array_length(struct_get_names(global.character_indexes)) + array_length(struct_get_names(global.custom_character_indexes));

for (var i = 0; i < array_length(struct_get_names(global.custom_character_indexes)); i++)
if (array_length(struct_get_names(global.custom_character_indexes)) > 0)
{
global.characters_unlocked[global.custom_character_indexes[$ struct_get_names(global.custom_character_indexes)[i]]] = true;
for (var i = 0; i < array_length(struct_get_names(global.custom_character_indexes)); i++)
{
global.characters_unlocked[global.custom_character_indexes[$ struct_get_names(global.custom_character_indexes)[i]]] = true;
}
}
}

function freakloader_add_chars()
{
if (array_length(struct_get_names(global.custom_character_indexes)) == 0) exit;

var customChars = struct_get_names(global.custom_character_indexes),
character_;

Expand All @@ -65,19 +70,19 @@ function freakloader_add_chars()
_character = global.custom_character_indexes[$ customChars[i]];
global.character_names[_character] = charFile.name;
player_animation_create(_character, player_animations.hud_face, sprite_add($"{filePath}/{charFile.sprites.path}/hud.png", 2, false, false, 16, 16));
player_animation_create(_character, player_animations.idle, sprite_add($"{filePath}/{charFile.sprites.path}/stand.png", 1, false, false, 24, 40));
player_animation_create(_character, player_animations.walk, sprite_add($"{filePath}/{charFile.sprites.path}/walk.png", 4, false, false, 24, 40));
player_animation_create(_character, player_animations.skid, spr_player_skid_scruffy);
player_animation_create(_character, player_animations.hurt, spr_player_hurt_scruffy);
player_animation_create(_character, player_animations.death, sprite_add($"{filePath}/{charFile.sprites.path}/death.png", 1, false, false, 24, 40));
player_animation_create(_character, player_animations.air, spr_player_air_scruffy);
player_animation_create(_character, player_animations.jump, sprite_add($"{filePath}/{charFile.sprites.path}/jump.png", charFile.sprites.jump.frames, false, false, charFile.sprites.jump.xorig, charFile.sprites.jump.yorig));
player_animation_create(_character, player_animations.wall_slide, spr_player_wall_slide_scruffy);
player_animation_create(_character, player_animations.hang, spr_player_hang_scruffy);
player_animation_create(_character, player_animations.climb, spr_player_climb_scruffy);
player_animation_create(_character, player_animations.pole_climb, spr_player_pole_scruffy);
player_animation_create(_character, player_animations.pole_turn, spr_player_pole_turn_scruffy);
player_animation_create(_character, player_animations.rail_grind, spr_player_rail_scruffy);
player_animation_create(_character, player_animations.idle, sprite_add($"{filePath}/{charFile.sprites.path}/stand.png", charFile.sprites.stand.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.walk, sprite_add($"{filePath}/{charFile.sprites.path}/walk.png", charFile.sprites.walk.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.skid, sprite_add($"{filePath}/{charFile.sprites.path}/skid.png", charFile.sprites.skid.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.hurt, sprite_add($"{filePath}/{charFile.sprites.path}/hurt.png", charFile.sprites.hurt.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.death, sprite_add($"{filePath}/{charFile.sprites.path}/death.png", charFile.sprites.death.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.air, sprite_add($"{filePath}/{charFile.sprites.path}/air.png", charFile.sprites.air.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.jump, sprite_add($"{filePath}/{charFile.sprites.path}/jump.png", charFile.sprites.jump.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.wall_slide, sprite_add($"{filePath}/{charFile.sprites.path}/wall_slide.png", charFile.sprites.wall_slide.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.hang, sprite_add($"{filePath}/{charFile.sprites.path}/hang.png", charFile.sprites.hang.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.climb, sprite_add($"{filePath}/{charFile.sprites.path}/climb.png", charFile.sprites.climb.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.pole_climb, sprite_add($"{filePath}/{charFile.sprites.path}/pole.png", charFile.sprites.pole.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.pole_turn, sprite_add($"{filePath}/{charFile.sprites.path}/pole_turn.png", charFile.sprites.pole_turn.frames, false, false, 0, 0));
player_animation_create(_character, player_animations.rail_grind, sprite_add($"{filePath}/{charFile.sprites.path}/rail.png", charFile.sprites.rail.frames, false, false, 0, 0));

player_mugshot_create(_character, sprite_add($"{filePath}/{charFile.sprites.path}/mugshot.png", 1, false, false, 32, 40));

Expand Down
8 changes: 5 additions & 3 deletions scripts/scr_player_characters/scr_player_characters.gml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ enum player_animations
count,
}

global.character_indexes.count = array_length(struct_get_names(global.character_indexes));
global.character_count = array_length(struct_get_names(global.character_indexes));

/// @function characters_init
function characters_init()
Expand All @@ -56,15 +56,15 @@ function characters_init()
global.player_deathsound = [];
global.characters_unlocked = [];

for (_i = 0; _i < global.character_indexes.count; ++_i)
for (_i = 0; _i < global.character_count; ++_i)
{
global.character_names[_i] = "";
global.characters_unlocked[_i] = false;
}

for (_i = 0; _i < player_animations.count; ++_i)
{
array_push(global.player_animation, array_create(global.character_indexes.count));
array_push(global.player_animation, array_create(global.character_count));
}

global.characters_unlocked[global.character_indexes.scruffy] = true;
Expand Down Expand Up @@ -563,6 +563,8 @@ function player_animation_create(_character_index, _animation_index, _sprite)
{
global.player_animation[_animation_index][_character_index] = _sprite;

if (_character_index >= 20 && _animation_index != player_animations.hud_face) sprite_set_offset(_sprite, max(0, sprite_get_width(_sprite) / 2), max(0, sprite_get_height(_sprite) - 24));

gml_pragma("forceinline");
}

Expand Down
Binary file modified sounds/msc_boss_kranion/msc_boss_kranion.ogg
Binary file not shown.
4 changes: 2 additions & 2 deletions sounds/msc_boss_kranion/msc_boss_kranion.yy

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit fb8a142

Please sign in to comment.