Mercurial > touhou
comparison src/th06/ecl_vm.rs @ 722:e71ea8214ee2
ecl_vm: some work on vampire fantasy
author | Gauvain "GovanifY" Roussel-Tarbouriech <gauvain@govanify.com> |
---|---|
date | Mon, 28 Oct 2019 21:19:50 +0100 |
parents | bbf0da7de481 |
children | 420cec4005b5 |
comparison
equal
deleted
inserted
replaced
721:bbf0da7de481 | 722:e71ea8214ee2 |
---|---|
986 let mut enemy = self.enemy.borrow_mut(); | 986 let mut enemy = self.enemy.borrow_mut(); |
987 let pos = [rand_x * range_x + enemy.pos.x as f64 - range_x / 2., | 987 let pos = [rand_x * range_x + enemy.pos.x as f64 - range_x / 2., |
988 rand_y * range_y + enemy.pos.x as f64 - range_y / 2.]; | 988 rand_y * range_y + enemy.pos.x as f64 - range_y / 2.]; |
989 enemy.bullet_attributes.fire(); | 989 enemy.bullet_attributes.fire(); |
990 } | 990 } |
991 8 => { // Vampire Fantasy | |
992 /* | |
993 let mut n = 0: | |
994 for bullet in game.bullets{ | |
995 if bullet._bullet_type.state != 0 && bullet._bullet_type.state != 5 && (30. <= (bullet.sprites[0].additional_infos)->height) { | |
996 local_5c.pos[0] = local_bullet_vec->pos[0]; | |
997 local_5c.pos[1] = local_bullet_vec->pos[1]; | |
998 local_5c.pos[2] = local_bullet_vec->pos[2]; | |
999 local_5c.anim = 3; | |
1000 local_5c.sprite_index_offset = 1; | |
1001 fVar3 = prng_double(&PRNG_STATE); | |
1002 local_5c.launch_angle = (self.get_prng().borrow_mut().get_f64() * (2. * std::f64::consts::PI) - std::f64::consts::PI) as f32; | |
1003 local_5c.speed = 0.00000000; | |
1004 local_5c.bullets_per_shot = 1; | |
1005 local_5c.nb_of_shots = 1; | |
1006 local_5c.flags = 8; | |
1007 local_5c.bullet_type = 1; | |
1008 bullet_fire(&local_5c,&ETAMA_ARRAY); | |
1009 } | |
1010 n += 1 | |
1011 } | |
1012 //TODO: this variable might not always be correct! it uses the argument in | |
1013 //th06: *(int *)(param_1 + 0x9b0) = local_60; | |
1014 self._setval(-10004, n) | |
1015 */ | |
1016 } | |
991 14 => { // Lävatein | 1017 14 => { // Lävatein |
992 let mut enemy = self.enemy.borrow_mut(); | 1018 let mut enemy = self.enemy.borrow_mut(); |
993 self.frame.ints1[3] = 0; | 1019 self.frame.ints1[3] = 0; |
994 for laser in enemy.laser_by_id.values() { | 1020 for laser in enemy.laser_by_id.values() { |
995 //for pos in laser.get_bullets_pos(){ | 1021 //for pos in laser.get_bullets_pos(){ |