ã¯ããã«
ãæè¿ã§ã¯ãä½äºãWebãã©ã¦ã¶ä¸ã®ã¿ã§å®çµãã¦ãã¾ããã¨ãå¤ãã®ã§ãã¡ãã£ã¨ãããã¹ã¯ãããã¢ããªã±ã¼ã·ã§ã³ãä½ã£ã¦ãããªããªãã¤ã³ã¹ãã¼ã«ãã¦ããããã¨ãã§ãã¾ãããããã§ãWebãã©ã¦ã¶ä¸ã§æ°è»½ã«ä½¿ã£ã¦ããããããã«ãFlashã¨PHPã使ã£ã¦ã¢ã¤ã³ã³ã¨ãã£ã¿ä½æãã¦ã¿ã¾ããã
ãç¾å¨ãã¢ã¤ã³ã³ã¨ãã£ã¿ã¯ãã¦ãã¦ã©ãã®ãã¼ã¸ã§å ¬éããã¦ãã¾ãã
ããã®ã¢ã¤ã³ã³ã¨ãã£ã¿ãå ã«ãã¤ã¤ãåãããããåºæ¬æ©è½ã ãããã¤ã¢ã¤ã³ã³ã¨ãã£ã¿ãä½ãéç¨ãç´¹ä»ãã¾ãã
対象èªè
- Flashã§ãã¼ã«ãæ軽ã«ä½ã£ã¦ã¿ããæ¹
- PHPã®GDã©ã¤ãã©ãªã®ä½¿ãæ¹ãç¥ãããæ¹
- Flash ActionScript2ãå¤å°åããæ¹
- PHPãå¤å°åããæ¹
å¿ è¦ãªç°å¢
ãæ¬ç¨¿ã®éçºã«ã¯ãFlash 8ãPHP 5ãå©ç¨ãã¾ããããªããFlashã¯MX 2004ãPHPã¯4ã§ãåããã¨ã確èªãã¾ããã
ä»åä½æãããã¼ã«ã®æ¦è¦
ãFlashã使ã£ã¦ç°¡åãªã¢ã¤ã³ã³ã¨ãã£ã¿ãä½ãã¾ããç°¡åãªæç»æ©è½ã®ã¿ãæãããã®ã§ã16x16ãããã®å°ããªã¢ã¤ã³ã³ãä½ãã ãã®ãã®ãä½ãã¾ãã
ãããã§ä½æããã¢ã¤ã³ã³ã¨ãã£ã¿ã¯ãçè ã®ãã¼ã¸ã§è©¦ããã¨ãã§ãã¾ãã
ããã®ãã¼ã«ã¯Flashã¨PHPãçµã¿åããã¦ä½ãã¾ãããããããã®åæ ã¯æ¬¡ã®ã¨ããã§ãã
- FLASHï¼ã¯ã©ã¤ã¢ã³ããµã¤ãï¼
- ã¢ã¤ã³ã³ã¨ãã£ã¿ã§ã¢ã¤ã³ã³ã®ãã¼ã¿ãä½ã
- PHPã¸ã¢ã¤ã³ã³ã®ãã¼ã¿ãéä¿¡ãã
- PHPï¼ãµã¼ãã¼ãµã¤ãï¼
- ã¢ã¤ã³ã³ã®ãã¼ã¿ãåãåã
- ãã¼ã¿ãå ã«GDã©ã¤ãã©ãªãå©ç¨ãã¦ç»åãæç»ãã
- ãã¡ã¤ã«ã¸ç»åãä¿åãã
Flashã ãã§ã¯ã§ããªãã®ãï¼
ãFlashã¯ããã©ã¦ã¶ä¸ã§åããã¨ãç®çã«ä½ããã¦ããã®ã§ãã»ãã¥ãªãã£ã«é æ ®ããã¦ãããFlashä¸ã§ä½ã£ããã¼ã¿ããã¯ã©ã¤ã¢ã³ãã®ã³ã³ãã¥ã¼ã¿ã«ä¿åããæ¹æ³ã¯éããã¦ãã¾ãã
ããã®ãããFlashã§ä½ã£ãã¢ã¤ã³ã³ãã¼ã¿ãä¿åããã«ã¯ãä¸åº¦ãµã¼ãå´ã«ä¿åãããã©ã¦ã¶ããç»åãã¡ã¤ã«ã¨ãã¦èªã¿è¾¼ãããã«ãã¾ãããã©ã¦ã¶ä¸ã«ç»åãã¡ã¤ã«ã表示ãããã°ãã¦ã¼ã¶ã¼ã¯ãã©ã¦ã¶ã«ããï¼»ååãä»ãã¦ç»åãä¿åï¼½ã¡ãã¥ã¼ããããã¼ã«ã«ãã¡ã¤ã«ã«ä¿åãããã¨ãã§ãã¾ãã
ãã¾ããFlashã®ActionScriptã ãã§GIFãªã©ã®ç»åãã¡ã¤ã«ãçæããã®ã¯å¤§å¤ãªã®ã§ãPHPã«ç¨æããã¦ããGDã©ã¤ãã©ãªãå©ç¨ãããã¨ã§ãæ軽ã«BMP/JPEG/GIF/PNGå½¢å¼ã®ç»åãä½æãããã¨ãã§ãã¾ãã
ããã ãFlash ActionScriptã¨PHPã¨ãã2ã¤ã®è¨èªã使ãåããªããã°ãããªãã®ã§ãå¤å°æ··ä¹±ããå ´åãããã¾ããããã¾ãé ãåãæ¿ãã¦ä¹ãåã£ã¦ãã ããã
Flash ActionScript2ããã¾ãæ´»ç¨ããã
ãã¢ã¤ã³ã³ã¨ãã£ã¿ã®ãããªãã¼ã«ãæ軽ã«ä½ãã³ãã¯ãFlash ActionScript2ã§å¼·åãããåãã§ãã¯ããã¾ã使ããã¨ã§ããActionScriptã§ã¯ãæªå®ç¾©ã®å¤æ°ãundefinedã¨ãã¦è¡¨ããã綴ããã¹ããã£ã¦ãã¨ã©ã¼ãåºãªãã®ã§ãç°¡åãªãã¹ãæ¢ãã®ã大å¤ã§ãã
ããã®ãããçè
ã¯ç°¡åãªç¶´ããã¹ãè¦ã¤ããããã«ãtrace()
é¢æ°ãè³ãæã«åãè¾¼ãã§ãæªå®ç¾©ã®å¤æ°ãæ¢ãã®ã«è¦å´ããçµé¨ãä½åº¦ãããã¾ããç¹ã«ã ã¼ãã¼ã¯ãªããã®ãã¹ãè¤éã«å
¥ãçµãã§ãããããã¨å°çã§ãã
ãããã§ãActionScript2ã§å¼·åãããåãã§ãã¯ããã¾ã使ãã¨ãã¨ã©ã¼ã¡ãã»ã¼ã¸ã表示ããã綴ããã¹ãçºè¦ãããããªãã¾ãã
ãã¾ããActionScriptã§ã¯ãã¯ã©ã¹ãå¤é¨ãã¡ã¤ã«ã«åãã¦æ¸ããã¨ãã§ããã®ã§ãã¤ã³ã¿ã¼ãã§ã¤ã¹ã ããFlashã®éçºç°å¢ã§ä½æãã¦ãããã¯ã©ã¹ãã¡ã¤ã«ãå¤é¨ã¨ãã£ã¿ã§ç·¨éãããã¨ãã§ãã¾ãã
ãæ¬ç¨¿ã§ããFlash 8ã®éçºç°å¢ã使ã£ã¦æ¸ããããã°ã©ã ã¯ã以ä¸ã®ä¸è¡ã ãã§ãã
new IconEditor();
ãããã¯ãå¤é¨ãã¡ã¤ã«ã«ãããIconEditor.asãã§å®ç¾©ããã¦ããIconEditor
ã¯ã©ã¹ãçæããã¨ããæå³ã«ãªãã¾ãã
ãå ãã¦ãFlash 8ã®æ¨æºActionScriptã¨ãã£ã¿ã«ã¯ãã³ã¼ãã®è£å®æ©è½ããããã®ã®ããããããFlashã«ç¨æããã¦ããçµã¿è¾¼ã¿ã®ã¯ã©ã¹ããè£å®ãã¦ããã¾ããããã®ãããã¡ã½ããåãæ¸ãééãããããã«ããä½åº¦ãå¼ããªãã¦ã¯ãªãããéçºå¹çãæªãã§ãã
ãç§ã¯ãèªä½ã®ActionScriptã¨ãã£ã¿ãas2editããä½ã£ã¦æ´»ç¨ãã¦ãã¾ããããã¯ãã©ããã¦ãèªä½ã¯ã©ã¹ã®ã¡ã½ãããèªåè£å®ããæ©è½ã欲ããã¦ä½ã£ããã®ã§ãï¼ããªã¼ã®Flashã³ã³ãã¤ã©ãMTASCãã«ã対å¿ãã¦ãã¾ãï¼ã
ãä»ã«ããæµ·å¤è£½ã®ActionScriptå°ç¨ã¨ãã£ã¿ããããããªã®ã§ããã¡ããå©ç¨ããã®ãè¯ãã§ãããã