Advertisement
Guest User

Untitled

a guest
Apr 8th, 2019
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ///scr_import(char,name,number)
  2. ini_open("dev_mode\dev_ver_0.6\active\custom_" +argument0 + ".ini")
  3. global.char = argument0
  4. global.movename = argument1
  5. global.hitboxnumber = argument2
  6. if global.hitboxnumber != "" {global.hitboxstring = "_" + string(global.hitboxnumber,)}
  7. else global.hitboxstring = ""
  8. if string(global.hitboxnumber) = "1" and ini_key_exists(argument1, "parent_hitbox") {global.hitboxnumber = "" global.hitboxstring = ""}
  9.  
  10. //These variables here do not have "multihit" in them if multihit
  11. global.creationframe = ini_read_real(argument1,"hitbox_window_creation_frame"+string(global.hitboxstring),0)
  12. global.hitboxwindow = ini_read_real(argument1,"hitbox_window"+string(global.hitboxstring),2)
  13. global.lifetime = ini_read_real(argument1,"hitbox_lifetime"+string(global.hitboxstring),1)
  14. with obj_hitbox {
  15. posy = ini_read_real(argument1,"hitbox_position_y"+string(global.hitboxstring),-10)
  16. posx = ini_read_real(argument1,"hitbox_position_x"+string(global.hitboxstring),10)
  17. x = obj_hurtbox.x + posx
  18. y = obj_hurtbox.y + posy
  19. }
  20.  
  21. //Adding everything from here has a different key name if it's a multihit hitbox
  22. if global.hitboxnumber != "" {global.hitboxstring = "_" + string(ini_read_real(argument1,"parent_hitbox_" + string(global.hitboxnumber),1))}
  23. if ini_key_exists(argument1,"base_knockback_multihit"+global.hitboxstring) {
  24. global.hitboxstring = "_multihit" + global.hitboxstring
  25. }
  26.  
  27. global.hiteffect =  ini_read_real(argument1,"hit_effect"+string(global.hitboxstring),0)
  28. global.damage = ini_read_real(argument1,"damage"+string(global.hitboxstring),5)
  29. global.scaling = ini_read_real(argument1,"knockback_scaling"+string(global.hitboxstring),0.5)
  30.  
  31.  
  32.  
  33. with obj_effects {
  34. image_index = global.hiteffect
  35. if global.hiteffect = 0 mode = 0
  36. if global.hiteffect = 1 mode = 1
  37. if global.hiteffect = 5 mode = 2
  38. if global.hiteffect = 8 mode = 3
  39. if global.hiteffect = 9 mode = 4
  40. if global.hiteffect = 10 mode = 5
  41. if global.hiteffect = 11 mode = 6
  42. }
  43.  
  44. with obj_hitbox {
  45. mode = ini_read_real(argument1,"hitbox_shape"+string(global.hitboxstring),0)
  46. height = ini_read_real(argument1,"hitbox_size_y"+string(global.hitboxstring),50)
  47. width = ini_read_real(argument1,"hitbox_size_x"+string(global.hitboxstring),50)
  48. }
  49.  
  50. with obj_arrow {
  51. dir = ini_read_real(argument1,"knockback_angle"+string(global.hitboxstring),361)
  52. baseknockback = ini_read_real(argument1,"base_knockback"+string(global.hitboxstring),2)
  53. image_angle = dir
  54. }
  55.  
  56.  
  57. //for "displaying hitbox x out of y"
  58. global.num = ini_read_real(argument1,"num_hitboxes", 1)
  59. ini_close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement