comparison src/th06/ecl_vm.rs @ 725:fbf89cba04e2

ecl_vm: some work on spellcard 11
author Gauvain "GovanifY" Roussel-Tarbouriech <gauvain@govanify.com>
date Tue, 29 Oct 2019 15:41:23 +0100
parents 8acaf45b47d0
children 414f8611f344
comparison
equal deleted inserted replaced
724:8acaf45b47d0 725:fbf89cba04e2
1027 //TODO: this variable might not always be correct! it uses the argument in 1027 //TODO: this variable might not always be correct! it uses the argument in
1028 //th06: *(int *)(param_1 + 0x9b0) = local_60; 1028 //th06: *(int *)(param_1 + 0x9b0) = local_60;
1029 self._setval(-10004, n) 1029 self._setval(-10004, n)
1030 */ 1030 */
1031 } 1031 }
1032 11 => {
1033 self.get_prng().borrow_mut().get_f64();
1034 //TODO: the game does that
1035 //drop_particle(&PARTICLES_ARRAY,0xc,enemy->pos,1,0xffffffff);
1036 //self._game.new_effect((enemy.x, enemy.y), 17)
1037 /*
1038 for bullet in game.bullets {
1039 if bullet._bullet_type.state != 0 && bullet._bullet_type.state != 5 && (30. <= (bullet.sprites[0].additional_infos)->height) && bullet.speed == 0. {
1040 bullet.flags = bullet.flags | 0x10;
1041 //TODO: reverse this field and effect
1042 bullet->field_0x5ba = 2;
1043 new_effect(GAME_OBJECT,(sprite *)bullet, (int)bullet->sprites[0].sometimes_copy_of_UNK1 + (int)bullet->field_0x5ba);
1044 bullet.speed=0.01;
1045 bullet.frame=0x78;
1046 let mut angle = self.get_prng().borrow_mut().get_f64() * (2*std::f64::consts::PI) - std::f64::consts::PI;
1047 bullet->attributes[0] = cos(angle) * 0.01000000;
1048 bullet->attributes[1] = sin(angle) * 0.01000000;
1049
1050
1051 }
1052 }
1053 */
1054 }
1032 13 => { 1055 13 => {
1033 if self.frame.ints1[3] % 6 == 0 { 1056 if self.frame.ints1[3] % 6 == 0 {
1034 let mut _angle=self.frame.floats[2]; 1057 let mut _angle=self.frame.floats[2];
1035 /* 1058 /*
1036 (type_, anim, sprite_idx_offset, bullets_per_shot, number_of_shots, 1059 (type_, anim, sprite_idx_offset, bullets_per_shot, number_of_shots,