¢¤Ë¤Ä¤¤Þ¤·¤Æ¡¢¥É¥Ã¥È¥µ¡¼¥¯¥ë¥¢¥Ë¥á¡¼¥·¥ç¥ó¤òºî¤Ã¤Æ¤ß¤Þ¤·¤¿¡£
¤¢¤Þ¤ê¥ê¥¢¥ë¤Ë¤ÏºÆ¸½¤Ç¤¤Ê¤«¤Ã¤¿¤«¤â¤·¤ì¤Þ¤»¤ó¤¬¡¢¤È¤ê¤¢¤¨¤º¡£
#include "winmm.as"
#module
//canm_init p1,p2,p3,p4,p5,p6,p7,p8,p9,p10,p11
// ¥É¥Ã¥È¥µ¡¼¥¯¥ë¥¢¥Ë¥áɽ¼¨¤Î½é´üÀßÄê¤ò¹Ô¤¦¡£
// ¼Â¹Ô¸å¡¢ÉÁ²èÎΰè¤ÎÀµÊý·Á¤Î°ìÊÕ¤ÎŤµ¤¬stat¤ËÆþ¤ë¡£
// ¥É¥Ã¥È¥µ¡¼¥¯¥ë¥¢¥Ë¥áÃæ¤Ïsetease¤ägetease¤Ï»È¤ï¤Ê¤¤¤³¤È¡£
//p1,p2 : ¤³¤Î½èÍý¤ÇÍѤ¤¤ë²èÁü¥Ð¥Ã¥Õ¥¡¤ÎÈÖ¹æ
//p3 : ¥É¥Ã¥È¤ÎȾ·Â
//p4 : ¸øžȾ·Â
//p5,p6,p7 : ¥É¥Ã¥È¤Î¿§(r,g,b) 0,0,0¤Ï»ÈÍÑÉÔ²Ä
//p8,p9,p10 : Çطʤο§(r,g,b)
//p11 : °ì¼þ¤Ë¤«¤«¤ë»þ´Ö(¥ß¥êÉÃ)
#deffunc canm_init int _buf1,int _buf2,int _r0,int _r1,int cr0,int cg0,int cb0,int cr1,int cg1,int cb1,int msec
now_buf=ginfo_sel
buf1=_buf1 //ºî¶È¤ÇÍѤ¤¤ë¥Ð¥Ã¥Õ¥¡ÈÖ¹æ1
buf2=_buf2 //ºî¶È¤ÇÍѤ¤¤ë¥Ð¥Ã¥Õ¥¡ÈÖ¹æ2
r0=_r0 //¥É¥Ã¥È¤ÎȾ·Â
d0=r0*2 //¥É¥Ã¥È¤Îľ·Â
r1=_r1 //¸øž¤ÎȾ·Â
d1=r1*2+d0 //ÉÁ²èÎΰè¤ÎÀµÊý·Á¤Î°ìÊÕ¤ÎŤµ
buffer buf1,d0,d0 : gsel buf1
color 0,0,0 : boxf
color cr0,cg0,cb0 : circle 0,0,d0,d0,1
buffer buf2,d1,d1 : gsel buf2
color cr1,cg1,cb1 : boxf
gsel now_buf
c_cou=msec/33 //°ì¼þ¤Ë¤«¤«¤ë¥«¥¦¥ó¥È¿ô(1¥«¥¦¥ó¥È¤Ï1/30ÉÃ)
c_cou2=c_cou*2 //Æó¼þ¤Ë¤«¤«¤ë¥«¥¦¥ó¥È¿ô
h_cou=c_cou/5 //¥«¥¦¥ó¥È¤¬¤³¤Î¿ôÃͤˤʤë¤Þ¤Ç¤Ï¥É¥Ã¥È¤òɽ¼¨¤·¤Ê¤¤
h_cou2=c_cou2-h_cou //¥«¥¦¥ó¥È¤¬¤³¤Î¿ôÃͤˤʤ俤é¥É¥Ã¥È¤òɽ¼¨¤·¤Ê¤¤
g_cou=c_cou/16 //¥É¥Ã¥È1¸Ä¤´¤È¤Î¥«¥¦¥ó¥Èº¹
cou0=-1
TimeGetTime : start_t=stat
setease M_PI*0.5,M_PI*2.5,ease_quad_inout
return d1
//canm p1,p2
// ¥É¥Ã¥È¥µ¡¼¥¯¥ë¥¢¥Ë¥á¤òɽ¼¨
// ¤³¤ì¤ò¼Â¹Ô¤¹¤ëÁ°¤Ëcanm_init¤ò¼Â¹Ô¤·¤Æ¤ª¤¯¤³¤È¡£
//p1 : 1¤Î»þ¤Ïredraw½èÍý¤ò¹Ô¤¦(¾Êά²Ä¡£¾Êά»þ¤Ï1)
//p2 : 1¤Î»þ¤ÏÇطʤò½é´ü²½¤¹¤ë(¾Êά²Ä¡£¾Êά»þ¤Ï1)
#define global canm(%1=1,%2=1) _canm %1,%2
#deffunc _canm int swi,int swi2
TimeGetTime : cou=((stat-start_t)/33)\c_cou2 //¥«¥¦¥ó¥ÈÃͤò¼èÆÀ
if cou=cou0 : return //Á°²ó¤³¤ì¤ò¼Â¹Ô¤·¤¿»þ¤È¥«¥¦¥ó¥ÈÃͤ¬ÊѤï¤é¤Ê¤¤¤Ê¤é²¿¤â¤·¤Ê¤¤
cou0=cou
if swi : redraw 0
x=ginfo_cx : y=ginfo_cy
if swi2 {
gmode 0
gcopy buf2,0,0,d1,d1
}
gmode 2
x0=x+r1+r0 : y0=y+r1+r0 //¸øž¤ÎÃæ¿´
repeat 5
cou1=cou+cnt*g_cou
if (cou1>h_cou)&(cou1<h_cou2) {
rad=geteasef(cou1\c_cou,c_cou)
pos int(cos(rad)*r1)+x0-r0,int(sin(rad)*r1)+y0-r0
gcopy buf1,0,0,d0,d0
}
loop
if swi : redraw 1,x,y,d1,d1
pos x,y
return
#global
//°Ê²¼¥µ¥ó¥×¥ë
color 0,0,0 : boxf
canm_init 100,101,4,30,255,255,255,0,0,0,2200
pos 100,100
repeat
canm
await 33
loop