Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Draw the right click task bar
- //////////////////////
- //Horizontal Sliders//
- //////////////////////
- /////////
- //Go Here
- if point_distance(guix,guiy,1243,144) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,122)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,122)
- }
- }
- /////////
- //Get Wood
- else if point_distance(guix,guiy,1243,193) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,171)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,171)
- }
- }
- /////////
- //Get Stone
- else if point_distance(guix,guiy,1243,243) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,220)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,220)
- }
- }
- /////////
- //Get Food
- else if point_distance(guix,guiy,1243,292) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,269)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,269)
- }
- }
- /////////
- //Empty Inventory
- else if point_distance(guix,guiy,1243,341) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,318)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,318)
- }
- }
- /////////
- //Bury Dead
- else if point_distance(guix,guiy,1243,390) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,367)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,367)
- }
- }
- /////////
- //Return Home
- else if point_distance(guix,guiy,1243,439) <= 22
- {
- hor_slidetimer += 16
- //Draw the tooltip at different distances depending on hor_slidetimer
- if hor_slidetimer < 226
- {
- //Draw horizontal slide
- draw_sprite(spr_taskgui_hor_gohere,0,1206-hor_slidetimer,416)
- }
- else
- {
- draw_sprite(spr_taskgui_hor_gohere,0,980,416)
- }
- }
- else
- {
- hor_slidetimer = 0
- }
- /////////////////////
- //Draw Task Options//
- /////////////////////
- if vert_slidetimer <= 400
- {
- //Draw the vertical task sliding down
- vert_slidetimer += 16
- draw_sprite(spr_taskgui_vertslide,0,1206,73-400+vert_slidetimer)
- }
- else
- {
- draw_sprite(spr_taskgui_vertslide,0,1206,73);
- }
- ///////////////////////////
- //Draw Hoizontal Cover-Up//
- ///////////////////////////
- /////////////
- //Go Here
- if point_distance(guix,guiy,1243,144) <= 22 and hor_slidetimer >0
- {
- //Draw cover up to make slide look like it's sliding out of task menu
- draw_sprite(spr_gui_cover,0,1206,122)
- }
- /////////////
- //Get Wood
- else if point_distance(guix,guiy,1243,193) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,171)
- }
- /////////////
- //Get Stone
- else if point_distance(guix,guiy,1243,243) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,220)
- }
- /////////////
- //Get Food
- else if point_distance(guix,guiy,1243,292) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,269)
- }
- /////////////
- //Empty Inventory
- else if point_distance(guix,guiy,1243,341) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,318)
- }
- /////////////
- //Bury Dead
- else if point_distance(guix,guiy,1243,390) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,367)
- }
- /////////////
- //Return Home
- else if point_distance(guix,guiy,1243,439) <= 22 and hor_slidetimer >0
- {
- draw_sprite(spr_gui_cover,0,1206,416)
- }
- //////////////////////
- //Draw Mouseover GUI//
- //////////////////////
- draw_set_font (fnt_header);
- draw_sprite(spr_mouseover_friendly,0,980,0);
- draw_sprite(face_sprite,0,985,5);
- draw_set_colour(c_white);
- draw_text(1080,10,string(name)); //Write name
- //Hpbar
- hpbar = curhp/maxhp * 200
- draw_set_colour(c_black);
- draw_rectangle(1058,48,1262,67,0);//black
- draw_set_colour(c_white);
- draw_rectangle(1060,50,1260,65,0);//whitebackground
- draw_set_colour(c_red);
- draw_rectangle(1060,50,1060+hpbar,65,0);//redbar
- draw_set_font (fnt_sm_display);//Set Font
- draw_set_colour(c_black);
- draw_text(1065,49,string(curhp) + "/"+ string(maxhp));
- if joy >= 75
- {
- draw_sprite(spr_joy_green,0,1060,15);
- }
- else if joy < 75 and joy >= 25
- {
- draw_sprite(spr_joy_yellow,0,1060,15);
- }
- else if joy < 25
- {
- draw_sprite(spr_joy_red,0,1060,15);
- }
- ///////////////
- //Handle Exit//
- ///////////////
- if keyboard_check (vk_escape) and click_timer > 15 and global.gui = 102
- {
- click_timer = 0;
- global.gui = 0;
- this_unit = 0;
- vert_slidetimer = 0
- //sound
- }
Advertisement
Add Comment
Please, Sign In to add comment