C
cheque
Guest
I'm currently working on a hot bar for spells in my game, and I got something working but I think its just way to much unnecessary code. I was hopefully one of you Game maker wizards could help me. anyways code:
I only provided the code I'm using for the spell cooldown. here are 4 examples of what it looks like
if this is not enough information I will gladly provide more. again sorry for my horrible programming skills lol, thank you for any help
wep_select = 0;
Spell_slot1 =0;
Spell_slot2 =0;
Spell_slot3 =0;
Spell_slot4 =0;
Spell_slot5 =0;
Spell_slot1_cooldown = 0;
Spell_slot2_cooldown = 0;
Spell_slot3_cooldown = 0;
Spell_slot4_cooldown = 0;
Spell_slot5_cooldown = 0;
Ss1c = Spell_slot1_cooldown;
Ss2c = Spell_slot2_cooldown;
Ss3c = Spell_slot3_cooldown;
Ss4c = Spell_slot4_cooldown;
Ss5c = Spell_slot5_cooldown;
CoolDalpha = 0;
CoolDalpha2 = 0;
CoolDalpha3 = 0;
CoolDalpha4 = 0;
CoolDalpha5 = 0;
OutlineColor = 0;
OutlineColor2 = 0;
OutlineColor3 = 0;
OutlineColor4 = 0;
OutlineColor5 = 0;
Spell_slot1 =0;
Spell_slot2 =0;
Spell_slot3 =0;
Spell_slot4 =0;
Spell_slot5 =0;
Spell_slot1_cooldown = 0;
Spell_slot2_cooldown = 0;
Spell_slot3_cooldown = 0;
Spell_slot4_cooldown = 0;
Spell_slot5_cooldown = 0;
Ss1c = Spell_slot1_cooldown;
Ss2c = Spell_slot2_cooldown;
Ss3c = Spell_slot3_cooldown;
Ss4c = Spell_slot4_cooldown;
Ss5c = Spell_slot5_cooldown;
CoolDalpha = 0;
CoolDalpha2 = 0;
CoolDalpha3 = 0;
CoolDalpha4 = 0;
CoolDalpha5 = 0;
OutlineColor = 0;
OutlineColor2 = 0;
OutlineColor3 = 0;
OutlineColor4 = 0;
OutlineColor5 = 0;
var spell_cd = obj_magicTree_GUI.ds_spell_info; //contaning all the cooldowns in a ds list
if keyboard_check_pressed(ord("1"))
{
wep_select = 1;
if Ss1c = Spell_slot1_cooldown{
Spell_slot1 = ds_MagicTree[# 0,0]; //ds_MagicTree is the actual ds_list for the hotbar ranging from 0-4
if Spell_slot1 > 0{
Spell_slot1_cooldown = spell_cd[# 2,Spell_slot1];
Ss1c = Spell_slot1_cooldown;
Ss1c -= .05;}
}}
if keyboard_check_pressed(ord("2"))
{
wep_select = 2;
if Ss2c = Spell_slot2_cooldown{
Spell_slot2 = ds_MagicTree[# 0,1];
if Spell_slot2 > 0{
Spell_slot2_cooldown = spell_cd[# 2,Spell_slot2];
Ss2c = Spell_slot2_cooldown;
Ss2c -= .05;}
}}
if keyboard_check_pressed(ord("3"))
{
wep_select = 3;
if Ss3c = Spell_slot3_cooldown{
Spell_slot3 = ds_MagicTree[# 0,2];
if Spell_slot3 > 0{
Spell_slot3_cooldown = spell_cd[# 2,Spell_slot3];
Ss3c = Spell_slot3_cooldown;
Ss3c -= .05;}
}}
if keyboard_check_pressed(ord("4"))
{
wep_select = 4;
if Ss4c = Spell_slot4_cooldown{
Spell_slot4 = ds_MagicTree[# 0,3];
if Spell_slot4 > 0{
Spell_slot4_cooldown = spell_cd[# 2,Spell_slot4];
Ss4c = Spell_slot4_cooldown;
Ss4c -= .05;}
}}
if keyboard_check_pressed(ord("5"))
{
wep_select = 5;
if Ss5c = Spell_slot5_cooldown{
Spell_slot5 = ds_MagicTree[# 0,4];
if Spell_slot5 > 0{
Spell_slot5_cooldown = spell_cd[# 2,Spell_slot5];
Ss5c = Spell_slot5_cooldown;
Ss5c -= .05;}
}}
var Sps1_c = ds_MagicTree[# 0,0];
var Sps2_c = ds_MagicTree[# 0,1];
var Sps3_c = ds_MagicTree[# 0,2];
var Sps4_c = ds_MagicTree[# 0,3];
var Sps5_c = ds_MagicTree[# 0,4];
if Sps1_c != Spell_slot1 {OutlineColor = make_color_rgb(255,0,0); Ss1c =Spell_slot1_cooldown;}
if Sps2_c != Spell_slot2 {OutlineColor2 = make_color_rgb(255,0,0); Ss2c =Spell_slot2_cooldown;}
if Sps3_c != Spell_slot3 {OutlineColor3 = make_color_rgb(255,0,0); Ss3c =Spell_slot3_cooldown;}
if Sps4_c != Spell_slot4 {OutlineColor4 = make_color_rgb(255,0,0); Ss4c =Spell_slot4_cooldown;}
if Sps5_c != Spell_slot5 {OutlineColor5 = make_color_rgb(255,0,0); Ss5c =Spell_slot5_cooldown;}
#region cooldown Ss1c/Spell_slot1_cooldown
if (Ss1c <= 0){Ss1c = Spell_slot1_cooldown;}
if (Ss1c < Spell_slot1_cooldown){Ss1c -= .05;}
if (Ss1c = Spell_slot1_cooldown){CoolDalpha = 0;} else {CoolDalpha = 1;}
if Ss1c = Spell_slot1_cooldown{OutlineColor = make_color_rgb(0,255,255);} // blue
if Ss1c < Spell_slot1_cooldown and Ss1c > Spell_slot1_cooldown-(Spell_slot1_cooldown*.4){OutlineColor = make_color_rgb(255,0,0);}// red
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.4){OutlineColor = make_color_rgb(255,100,0);}// orange
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.6){OutlineColor = make_color_rgb(255,200,0);} // yellow
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.8){OutlineColor = make_color_rgb(8,255,0);}// green
if (Ss2c <= 0){Ss2c = Spell_slot2_cooldown;}
if (Ss2c < Spell_slot2_cooldown){Ss2c -= .05;}
if (Ss2c = Spell_slot2_cooldown){CoolDalpha2 = 0;} else {CoolDalpha2 = 1;}
if Ss2c = Spell_slot2_cooldown{OutlineColor2 = make_color_rgb(0,255,255);} // blue
if Ss2c < Spell_slot2_cooldown and Ss2c > Spell_slot2_cooldown-(Spell_slot2_cooldown*.4){OutlineColor2 = make_color_rgb(255,0,0);}// red
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.4){OutlineColor2 = make_color_rgb(255,100,0);}// orange
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.6){OutlineColor2 = make_color_rgb(255,200,0);} // yellow
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.8){OutlineColor2 = make_color_rgb(8,255,0);}// green
if (Ss3c <= 0){Ss3c = Spell_slot3_cooldown;}
if (Ss3c < Spell_slot3_cooldown){Ss3c -= .05;}
if (Ss3c = Spell_slot3_cooldown){CoolDalpha3 = 0;} else {CoolDalpha3 = 1;}
if Ss3c = Spell_slot3_cooldown{OutlineColor3 = make_color_rgb(0,255,255);} // blue
if Ss3c < Spell_slot3_cooldown and Ss3c > Spell_slot3_cooldown-(Spell_slot3_cooldown*.4){OutlineColor3 = make_color_rgb(255,0,0);}// red
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.4){OutlineColor3 = make_color_rgb(255,100,0);}// orange
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.6){OutlineColor3 = make_color_rgb(255,200,0);} // yellow
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.8){OutlineColor3 = make_color_rgb(8,255,0);}// green
if (Ss4c <= 0){Ss4c = Spell_slot4_cooldown;}
if (Ss4c < Spell_slot4_cooldown){Ss4c -= .05;}
if (Ss4c = Spell_slot4_cooldown){CoolDalpha4 = 0;} else {CoolDalpha4 = 1;}
if Ss4c = Spell_slot4_cooldown{OutlineColor4 = make_color_rgb(0,255,255);} // blue
if Ss4c < Spell_slot4_cooldown and Ss4c > Spell_slot4_cooldown-(Spell_slot4_cooldown*.4){OutlineColor4 = make_color_rgb(255,0,0);}// red
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.4){OutlineColor4 = make_color_rgb(255,100,0);}// orange
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.6){OutlineColor4 = make_color_rgb(255,200,0);} // yellow
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.8){OutlineColor4 = make_color_rgb(8,255,0);}// green
if (Ss5c <= 0){Ss5c = Spell_slot5_cooldown;}
if (Ss5c < Spell_slot5_cooldown){Ss5c -= .05;}
if (Ss5c = Spell_slot5_cooldown){CoolDalpha5 = 0;} else {CoolDalpha5 = 1;}
if Ss5c = Spell_slot5_cooldown{OutlineColor5 = make_color_rgb(0,255,255);} // blue
if Ss5c < Spell_slot5_cooldown and Ss5c > Spell_slot5_cooldown-(Spell_slot5_cooldown*.4){OutlineColor5 = make_color_rgb(255,0,0);}// red
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.4){OutlineColor5 = make_color_rgb(255,100,0);}// orange
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.6){OutlineColor5 = make_color_rgb(255,200,0);} // yellow
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.8){OutlineColor5 = make_color_rgb(8,255,0);}// green
if keyboard_check_pressed(ord("1"))
{
wep_select = 1;
if Ss1c = Spell_slot1_cooldown{
Spell_slot1 = ds_MagicTree[# 0,0]; //ds_MagicTree is the actual ds_list for the hotbar ranging from 0-4
if Spell_slot1 > 0{
Spell_slot1_cooldown = spell_cd[# 2,Spell_slot1];
Ss1c = Spell_slot1_cooldown;
Ss1c -= .05;}
}}
if keyboard_check_pressed(ord("2"))
{
wep_select = 2;
if Ss2c = Spell_slot2_cooldown{
Spell_slot2 = ds_MagicTree[# 0,1];
if Spell_slot2 > 0{
Spell_slot2_cooldown = spell_cd[# 2,Spell_slot2];
Ss2c = Spell_slot2_cooldown;
Ss2c -= .05;}
}}
if keyboard_check_pressed(ord("3"))
{
wep_select = 3;
if Ss3c = Spell_slot3_cooldown{
Spell_slot3 = ds_MagicTree[# 0,2];
if Spell_slot3 > 0{
Spell_slot3_cooldown = spell_cd[# 2,Spell_slot3];
Ss3c = Spell_slot3_cooldown;
Ss3c -= .05;}
}}
if keyboard_check_pressed(ord("4"))
{
wep_select = 4;
if Ss4c = Spell_slot4_cooldown{
Spell_slot4 = ds_MagicTree[# 0,3];
if Spell_slot4 > 0{
Spell_slot4_cooldown = spell_cd[# 2,Spell_slot4];
Ss4c = Spell_slot4_cooldown;
Ss4c -= .05;}
}}
if keyboard_check_pressed(ord("5"))
{
wep_select = 5;
if Ss5c = Spell_slot5_cooldown{
Spell_slot5 = ds_MagicTree[# 0,4];
if Spell_slot5 > 0{
Spell_slot5_cooldown = spell_cd[# 2,Spell_slot5];
Ss5c = Spell_slot5_cooldown;
Ss5c -= .05;}
}}
var Sps1_c = ds_MagicTree[# 0,0];
var Sps2_c = ds_MagicTree[# 0,1];
var Sps3_c = ds_MagicTree[# 0,2];
var Sps4_c = ds_MagicTree[# 0,3];
var Sps5_c = ds_MagicTree[# 0,4];
if Sps1_c != Spell_slot1 {OutlineColor = make_color_rgb(255,0,0); Ss1c =Spell_slot1_cooldown;}
if Sps2_c != Spell_slot2 {OutlineColor2 = make_color_rgb(255,0,0); Ss2c =Spell_slot2_cooldown;}
if Sps3_c != Spell_slot3 {OutlineColor3 = make_color_rgb(255,0,0); Ss3c =Spell_slot3_cooldown;}
if Sps4_c != Spell_slot4 {OutlineColor4 = make_color_rgb(255,0,0); Ss4c =Spell_slot4_cooldown;}
if Sps5_c != Spell_slot5 {OutlineColor5 = make_color_rgb(255,0,0); Ss5c =Spell_slot5_cooldown;}
#region cooldown Ss1c/Spell_slot1_cooldown
if (Ss1c <= 0){Ss1c = Spell_slot1_cooldown;}
if (Ss1c < Spell_slot1_cooldown){Ss1c -= .05;}
if (Ss1c = Spell_slot1_cooldown){CoolDalpha = 0;} else {CoolDalpha = 1;}
if Ss1c = Spell_slot1_cooldown{OutlineColor = make_color_rgb(0,255,255);} // blue
if Ss1c < Spell_slot1_cooldown and Ss1c > Spell_slot1_cooldown-(Spell_slot1_cooldown*.4){OutlineColor = make_color_rgb(255,0,0);}// red
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.4){OutlineColor = make_color_rgb(255,100,0);}// orange
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.6){OutlineColor = make_color_rgb(255,200,0);} // yellow
if Ss1c = Spell_slot1_cooldown-(Spell_slot1_cooldown*.8){OutlineColor = make_color_rgb(8,255,0);}// green
if (Ss2c <= 0){Ss2c = Spell_slot2_cooldown;}
if (Ss2c < Spell_slot2_cooldown){Ss2c -= .05;}
if (Ss2c = Spell_slot2_cooldown){CoolDalpha2 = 0;} else {CoolDalpha2 = 1;}
if Ss2c = Spell_slot2_cooldown{OutlineColor2 = make_color_rgb(0,255,255);} // blue
if Ss2c < Spell_slot2_cooldown and Ss2c > Spell_slot2_cooldown-(Spell_slot2_cooldown*.4){OutlineColor2 = make_color_rgb(255,0,0);}// red
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.4){OutlineColor2 = make_color_rgb(255,100,0);}// orange
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.6){OutlineColor2 = make_color_rgb(255,200,0);} // yellow
if Ss2c = Spell_slot2_cooldown-(Spell_slot2_cooldown*.8){OutlineColor2 = make_color_rgb(8,255,0);}// green
if (Ss3c <= 0){Ss3c = Spell_slot3_cooldown;}
if (Ss3c < Spell_slot3_cooldown){Ss3c -= .05;}
if (Ss3c = Spell_slot3_cooldown){CoolDalpha3 = 0;} else {CoolDalpha3 = 1;}
if Ss3c = Spell_slot3_cooldown{OutlineColor3 = make_color_rgb(0,255,255);} // blue
if Ss3c < Spell_slot3_cooldown and Ss3c > Spell_slot3_cooldown-(Spell_slot3_cooldown*.4){OutlineColor3 = make_color_rgb(255,0,0);}// red
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.4){OutlineColor3 = make_color_rgb(255,100,0);}// orange
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.6){OutlineColor3 = make_color_rgb(255,200,0);} // yellow
if Ss3c = Spell_slot3_cooldown-(Spell_slot3_cooldown*.8){OutlineColor3 = make_color_rgb(8,255,0);}// green
if (Ss4c <= 0){Ss4c = Spell_slot4_cooldown;}
if (Ss4c < Spell_slot4_cooldown){Ss4c -= .05;}
if (Ss4c = Spell_slot4_cooldown){CoolDalpha4 = 0;} else {CoolDalpha4 = 1;}
if Ss4c = Spell_slot4_cooldown{OutlineColor4 = make_color_rgb(0,255,255);} // blue
if Ss4c < Spell_slot4_cooldown and Ss4c > Spell_slot4_cooldown-(Spell_slot4_cooldown*.4){OutlineColor4 = make_color_rgb(255,0,0);}// red
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.4){OutlineColor4 = make_color_rgb(255,100,0);}// orange
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.6){OutlineColor4 = make_color_rgb(255,200,0);} // yellow
if Ss4c = Spell_slot4_cooldown-(Spell_slot4_cooldown*.8){OutlineColor4 = make_color_rgb(8,255,0);}// green
if (Ss5c <= 0){Ss5c = Spell_slot5_cooldown;}
if (Ss5c < Spell_slot5_cooldown){Ss5c -= .05;}
if (Ss5c = Spell_slot5_cooldown){CoolDalpha5 = 0;} else {CoolDalpha5 = 1;}
if Ss5c = Spell_slot5_cooldown{OutlineColor5 = make_color_rgb(0,255,255);} // blue
if Ss5c < Spell_slot5_cooldown and Ss5c > Spell_slot5_cooldown-(Spell_slot5_cooldown*.4){OutlineColor5 = make_color_rgb(255,0,0);}// red
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.4){OutlineColor5 = make_color_rgb(255,100,0);}// orange
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.6){OutlineColor5 = make_color_rgb(255,200,0);} // yellow
if Ss5c = Spell_slot5_cooldown-(Spell_slot5_cooldown*.8){OutlineColor5 = make_color_rgb(8,255,0);}// green
#region //background color
if Ss5c != Spell_slot5_cooldown
{
d3d_set_fog(true, OutlineColor5, 0, 0);
draw_sprite_ext(select_h,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, c_white, 0, 0);
draw_sprite_ext(select_h,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss4c != Spell_slot4_cooldown
{
d3d_set_fog(true, OutlineColor4, 0, 0);
draw_sprite_ext(select_h,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor4, 0, 0);
draw_sprite_ext(select_h,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss3c != Spell_slot3_cooldown
{
d3d_set_fog(true, OutlineColor3, 0, 0);
draw_sprite_ext(select_h,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor3, 0, 0);
draw_sprite_ext(select_h,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss2c != Spell_slot2_cooldown
{
d3d_set_fog(true, OutlineColor2, 0, 0);
draw_sprite_ext(select_h,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor2, 0, 0);
draw_sprite_ext(select_h,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss1c != Spell_slot1_cooldown
{
d3d_set_fog(true, OutlineColor, 0, 0);
draw_sprite_ext(select_h,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor, 0, 0);
draw_sprite_ext(select_h,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
#endregion
#region //outline color
if _select = 5
{
d3d_set_fog(true, OutlineColor5, 0, 0);
draw_sprite_ext(select_h2,0,x+802-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor5, 0, 0);
draw_sprite_ext(select_h2,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 4
{
d3d_set_fog(true, OutlineColor4, 0, 0);
draw_sprite_ext(select_h2,0,x+770-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor4, 0, 0);
draw_sprite_ext(select_h2,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 3
{
d3d_set_fog(true, OutlineColor3, 0, 0);
draw_sprite_ext(select_h2,0,x+738-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor3, 0, 0);
draw_sprite_ext(select_h2,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 2
{
d3d_set_fog(true, OutlineColor2, 0, 0);
draw_sprite_ext(select_h2,0,x+706-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor2, 0, 0);
draw_sprite_ext(select_h2,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 1
{
d3d_set_fog(true, OutlineColor, 0, 0);
draw_sprite_ext(select_h2,0,x+674-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor, 0, 0);
draw_sprite_ext(select_h2,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
#endregion
var x1x = -130
var y1y = 502
draw_text_color(x+x1x,y+y1y,(round(Ss1c)),c_white,c_aqua,OutlineColor,OutlineColor,CoolDalpha);
draw_text_color(x+x1x+32,y+y1y,(round(Ss2c)),c_white,c_aqua,OutlineColor2,OutlineColor2,CoolDalpha2);
draw_text_color(x+x1x+64,y+y1y,(round(Ss3c)),c_white,c_aqua,OutlineColor3,OutlineColor3,CoolDalpha3);
draw_text_color(x+x1x+96,y+y1y,(round(Ss4c)),c_white,c_aqua,OutlineColor4,OutlineColor4,CoolDalpha4);
draw_text_color(x+x1x+128,y+y1y,(round(Ss5c)),c_white,c_aqua,OutlineColor5,OutlineColor5,CoolDalpha5);
if Ss5c != Spell_slot5_cooldown
{
d3d_set_fog(true, OutlineColor5, 0, 0);
draw_sprite_ext(select_h,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, c_white, 0, 0);
draw_sprite_ext(select_h,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss4c != Spell_slot4_cooldown
{
d3d_set_fog(true, OutlineColor4, 0, 0);
draw_sprite_ext(select_h,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor4, 0, 0);
draw_sprite_ext(select_h,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss3c != Spell_slot3_cooldown
{
d3d_set_fog(true, OutlineColor3, 0, 0);
draw_sprite_ext(select_h,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor3, 0, 0);
draw_sprite_ext(select_h,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss2c != Spell_slot2_cooldown
{
d3d_set_fog(true, OutlineColor2, 0, 0);
draw_sprite_ext(select_h,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor2, 0, 0);
draw_sprite_ext(select_h,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if Ss1c != Spell_slot1_cooldown
{
d3d_set_fog(true, OutlineColor, 0, 0);
draw_sprite_ext(select_h,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,.3);
d3d_set_fog(false, OutlineColor, 0, 0);
draw_sprite_ext(select_h,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
#endregion
#region //outline color
if _select = 5
{
d3d_set_fog(true, OutlineColor5, 0, 0);
draw_sprite_ext(select_h2,0,x+802-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor5, 0, 0);
draw_sprite_ext(select_h2,0,x+802-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 4
{
d3d_set_fog(true, OutlineColor4, 0, 0);
draw_sprite_ext(select_h2,0,x+770-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor4, 0, 0);
draw_sprite_ext(select_h2,0,x+770-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 3
{
d3d_set_fog(true, OutlineColor3, 0, 0);
draw_sprite_ext(select_h2,0,x+738-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor3, 0, 0);
draw_sprite_ext(select_h2,0,x+738-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 2
{
d3d_set_fog(true, OutlineColor2, 0, 0);
draw_sprite_ext(select_h2,0,x+706-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor2, 0, 0);
draw_sprite_ext(select_h2,0,x+706-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
if _select = 1
{
d3d_set_fog(true, OutlineColor, 0, 0);
draw_sprite_ext(select_h2,0,x+674-800,y+78+432,image_xscale+.1,image_yscale+.1,image_angle,image_blend,.5);
d3d_set_fog(false, OutlineColor, 0, 0);
draw_sprite_ext(select_h2,0,x+674-800,y+78+432,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
}
#endregion
var x1x = -130
var y1y = 502
draw_text_color(x+x1x,y+y1y,(round(Ss1c)),c_white,c_aqua,OutlineColor,OutlineColor,CoolDalpha);
draw_text_color(x+x1x+32,y+y1y,(round(Ss2c)),c_white,c_aqua,OutlineColor2,OutlineColor2,CoolDalpha2);
draw_text_color(x+x1x+64,y+y1y,(round(Ss3c)),c_white,c_aqua,OutlineColor3,OutlineColor3,CoolDalpha3);
draw_text_color(x+x1x+96,y+y1y,(round(Ss4c)),c_white,c_aqua,OutlineColor4,OutlineColor4,CoolDalpha4);
draw_text_color(x+x1x+128,y+y1y,(round(Ss5c)),c_white,c_aqua,OutlineColor5,OutlineColor5,CoolDalpha5);
I only provided the code I'm using for the spell cooldown. here are 4 examples of what it looks like
if this is not enough information I will gladly provide more. again sorry for my horrible programming skills lol, thank you for any help