Advertisement
Guest User

Testtt.txt

a guest
May 10th, 2018
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.19 KB | None | 0 0
  1. #TouhouDanmakufu[Single]
  2. #ScriptVersion[3]
  3. #Title["Fluidmovement"]
  4. #Text["New"]
  5. #include "script/default_system/Default_ShotConst.txt"
  6.  
  7. let objBoss;
  8. let objScene = GetEnemyBossSceneObjectID();
  9.  
  10. @Event{
  11. alternative(GetEventType())
  12. case(EV_REQUEST_LIFE){
  13. SetScriptResult(500);
  14. }
  15. case(EV_REQUEST_TIMER){
  16. SetScriptResult(60);
  17. }
  18. case(EV_REQUEST_SPELL_SCORE){
  19. SetScriptResult(1000000);
  20. }
  21. }
  22. @Initialize{
  23. objBoss = ObjEnemy_Create(OBJ_ENEMY_BOSS);
  24. ObjEnemy_Regist(objBoss);
  25. ObjMove_SetDestAtFrame(objBoss, GetCenterX(), 60, 60);
  26.  
  27. ObjEnemyBossScene_StartSpell(objScene);
  28.  
  29.  
  30. TDrawLoop;
  31. TFinalize;
  32. MainTask;
  33. }
  34. task TDrawLoop {
  35. let imgExRumia = GetCurrentScriptDirectory() ~ "ExRumia.png";
  36. ObjPrim_SetTexture(objBoss, imgExRumia);
  37. ObjSprite2D_SetSourceRect(objBoss, 64, 1, 127, 64);
  38. ObjSprite2D_SetDestCenter(objBoss);
  39.  
  40. }
  41. @MainLoop{
  42. ObjEnemy_SetIntersectionCircleToShot(objBoss, ObjMove_GetX(objBoss), ObjMove_GetY(objBoss), 32);
  43. ObjEnemy_SetIntersectionCircleToPlayer(objBoss, ObjMove_GetX(objBoss), ObjMove_GetY(objBoss), 24);
  44. yield;
  45. }
  46. task MainTask{
  47. while(ObjEnemy_GetInfo(objBoss, INFO_LIFE) > 0){
  48. loop(30){
  49. ascent(k in 0..5){
  50. let angleT = 90 + k;
  51. ascent(i in -1..2){
  52. ascent(j in 0..5){
  53. ascent(l in 0..5){
  54. //ObjMove_SetAngularVelocity(objBoss, 5);
  55. CreateShotA1(ObjMove_GetX(objBoss), ObjMove_GetY(objBoss), 3 - j/6,
  56. angleT + l*15, 89, 1);
  57.  
  58. }
  59.  
  60. }
  61.  
  62. angleT += 360/3;
  63. }
  64. wait(20);
  65. }
  66. wait(30);
  67. }
  68. }
  69. }
  70. task TFinalize {
  71. while(ObjEnemy_GetInfo(objBoss, INFO_LIFE) > 0){yield;}
  72. Obj_Delete(objBoss);
  73. DeleteShotAll(TYPE_ALL, TYPE_IMMEDIATE);
  74. SetAutoDeleteObject(true);
  75. CloseScript(GetOwnScriptID());
  76. return;
  77. if(ObjEnemyBossScene_GetInfo(objScene, INFO_PLAYER_SHOOTDOWN_COUNT)
  78. +ObjEnemyBossScene_GetInfo(objScene, INFO_PLAYER_SPELL_COUNT) == 0){
  79. AddScore(ObjEnemyBossScene_GetInfo(objScene, INFO_SPELL_SCORE));
  80. }
  81. }
  82. function GetCenterX(){
  83. return GetStgFrameWidth() / 2;
  84. }
  85. function GetCenterY(){
  86. return GetStgFrameHeight() / 2;
  87. }
  88. function wait(n){
  89. loop(n){yield;}
  90. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement