0
|
1 #include <stdlib.h>
|
|
2 #include "Character.h"
|
|
3 #include "Character_state.h"
|
|
4 //#include "Enemy.h"
|
|
5 #include "sankaku.h"
|
|
6 #include"debug.h"
|
|
7 #include <SDL_mixer.h>
|
|
8 #include "sound.h"
|
|
9
|
|
10 /*たまたまたま*/
|
|
11 /*tama.h*/
|
|
12 void Puttama(int type, float x, float y)
|
|
13 {
|
|
14 PlaySdlMixer(0, SHOT_B) ;// Enemys atack !!
|
|
15 TFon();
|
|
16 switch (type) {
|
|
17 case 0:
|
|
18 Putenemy(3, x, y, 0, 2, chara_state0);
|
|
19 Putenemy(3, x, y, (float) Mysin(15) * 2 / SANKAKU,
|
|
20 (float) Mycos(15) * 2 / SANKAKU, chara_state0);
|
|
21 Putenemy(3, x, y, (float) Mysin(30) * 2 / SANKAKU,
|
|
22 (float) Mycos(30) * 2 / SANKAKU, chara_state0);
|
|
23 Putenemy(3, x, y, (float) Mysin(-15) * 2 / SANKAKU,
|
|
24 (float) Mycos(-15) * 2 / SANKAKU, chara_state0);
|
|
25 Putenemy(3, x, y, (float) Mysin(-30) * 2 / SANKAKU,
|
|
26 (float) Mycos(-30) * 2 / SANKAKU, chara_state0);
|
|
27 break;
|
|
28 case 1:
|
|
29 Putenemy(3, x, y, (float) Mysin(rand() % 15) * 2 / SANKAKU,
|
|
30 (float) Mycos(rand() % 15) * 2 / SANKAKU, chara_state0);
|
|
31 Putenemy(3, x, y, (float) Mysin(rand() % 15) * 2 / SANKAKU,
|
|
32 (float) Mycos(rand() % 15) * 2 / SANKAKU, chara_state0);
|
|
33 // Putenemy(3,x,y,(float) Mysin(rand()%15)*2/SANKAKU,(float)Mycos(rand()%15)*2/SANKAKU,chara_state0);
|
|
34 // Putenemy(3,x,y,(float) Mysin(rand()%15)*2/SANKAKU,(float)Mycos(rand()%15)*2/SANKAKU,chara_state0);
|
|
35 // Putenemy(3,x,y,(float) Mysin(rand()%15)*2/SANKAKU,(float)Mycos(rand()%15)*2/SANKAKU,chara_state0);
|
|
36
|
|
37 Putenemy(3, x, y, (float) Mysin(rand() % 15 * -1) * 2 / SANKAKU,
|
|
38 (float) Mycos(rand() % 15 * -1) * 2 / SANKAKU, chara_state0);
|
|
39 Putenemy(3, x, y, (float) Mysin(rand() % 15 * -1) * 2 / SANKAKU,
|
|
40 (float) Mycos(rand() % 15 * -1) * 2 / SANKAKU, chara_state0);
|
|
41 // Putenemy(3,x,y,(float) Mysin(rand()%15*-1)*2/SANKAKU,(float)Mycos(rand()%15*-1)*2/SANKAKU,chara_state0);
|
|
42 // Putenemy(3,x,y,(float) Mysin(rand()%15*-1)*2/SANKAKU,(float)Mycos(rand()%15*-1)*2/SANKAKU,chara_state0);
|
|
43 // Putenemy(3,x,y,(float) Mysin(rand()%15*-1)*2/SANKAKU,(float)Mycos(rand()%15*-1)*2/SANKAKU,chara_state0);
|
|
44 break;
|
|
45
|
|
46 case 2:
|
|
47 Putenemy(6, x, y, 10, -3, chara_state20);
|
|
48 break;
|
|
49 case 3:
|
|
50 Putenemy(6, x, y, -10, -3, chara_state21);
|
|
51 break;
|
|
52 case 4:
|
|
53 Putenemy(7, x, y, 0, 15, chara_state0);
|
|
54 break;
|
|
55 case 5:
|
|
56 Putenemy(8, x, y, 0, 30, chara_state0);
|
|
57 break;
|
|
58 case 6: //本体
|
|
59 Putenemy(10, x, y, 0, 0, chara_state30);
|
|
60 break;
|
|
61 case 7:
|
|
62 Putenemy(6, x, y, 0, 4, chara_state0);
|
|
63 Putenemy(6, x, y, (float) Mysin(15) * 4 / SANKAKU,
|
|
64 (float) Mycos(15) * 4 / SANKAKU, chara_state0);
|
|
65 Putenemy(6, x, y, (float) Mysin(30) * 4 / SANKAKU,
|
|
66 (float) Mycos(30) * 4 / SANKAKU, chara_state0);
|
|
67 Putenemy(6, x, y, (float) Mysin(-15) * 4 / SANKAKU,
|
|
68 (float) Mycos(-15) * 4 / SANKAKU, chara_state0);
|
|
69 Putenemy(6, x, y, (float) Mysin(-30) * 4 / SANKAKU,
|
|
70 (float) Mycos(-30) * 4 / SANKAKU, chara_state0);
|
|
71 break;
|
|
72 case 8:
|
|
73 Putenemy(3, x + 8, y + 8, -4, 0, chara_state0);
|
|
74 Putenemy(3, x + 8, y + 8, 4, 0, chara_state0);
|
|
75 Putenemy(3, x + 8, y, -4, Mysin(30) * -8 / SANKAKU, chara_state0);
|
|
76 Putenemy(3, x + 8, y, 4, Mysin(30) * -8 / SANKAKU, chara_state0);
|
|
77 break;
|
|
78 case 9:
|
|
79 Putenemy(3, x + 8, y, -4, Mysin(30) * -8 / SANKAKU, chara_state0);
|
|
80 Putenemy(3, x + 8, y, 4, Mysin(30) * -8 / SANKAKU, chara_state0);
|
|
81 Putenemy(3, x + 8, y, -4, Mysin(30) * 8 / SANKAKU, chara_state0);
|
|
82 Putenemy(3, x + 8, y, 4, Mysin(30) * 8 / SANKAKU, chara_state0);
|
|
83 break;
|
|
84 case 10:
|
|
85 Putenemy(3, x + 8, y, -4, 0, chara_state0);
|
|
86 Putenemy(3, x + 8, y, 4, 0, chara_state0);
|
|
87 Putenemy(3, x + 8, y, 0, 4, chara_state0);
|
|
88 Putenemy(3, x + 8, y, 0, -4, chara_state0);
|
|
89 break;
|
|
90 case 11:
|
|
91 {
|
|
92 int a;
|
|
93 a = rand() % 360;
|
|
94
|
|
95 Putenemy(3, x + 8, y, (float) Mycos(a) / SANKAKU,
|
|
96 (float) Mysin(a) / SANKAKU, chara_state0);
|
|
97 }
|
|
98 }
|
|
99 TFoff();
|
|
100 }
|