# HG changeset patch
# User Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
# Date 1318971798 25200
# Node ID b96d835c0807d4f8ecaca784cffc948539f3a691
# Parent  e483b5a7e84b0c8c1a12924048282372ea05fc29
Implement Cirno’s 雪符「ダイアモンドブリザード」 spellcard.

diff --git a/pytouhou/vm/eclrunner.py b/pytouhou/vm/eclrunner.py
--- a/pytouhou/vm/eclrunner.py
+++ b/pytouhou/vm/eclrunner.py
@@ -856,6 +856,11 @@ class ECLRunner(object):
                     bullet.speed = 2.0 #TODO
                     bullet.angle = self._game.prng.rand_double() * pi #TODO
                     bullet.delta = (cos(bullet.angle) * bullet.speed, sin(bullet.angle) * bullet.speed)
+        elif function == 1: # Cirno
+            self._enemy.bullet_launch_offset = (
+                self._game.prng.rand_uint16() % arg - arg / 2,
+                self._game.prng.rand_uint16() % arg - arg / 2)
+            self._enemy.fire()
         else:
             logger.warn("Unimplemented special function %d!", function)