Project

General

Profile

Revision 227

implemented bullet movement and angle

View differences:

proj.c
145 145
        gunner_t *shooter2 = gunner_ctor(bsp_shooter, bsp_nothing);
146 146
        gunner_set_pos(shooter2, -50, -50);
147 147

  
148
        bullet_t *bullet = bullet_ctor(get_bullet());
149
        bullet_set_pos(bullet, 400, 400);
148
        bullet_t *bullet = bullet_ctor(get_bullet(), 400.0, 400.0, 2.0, -1.0);
150 149

  
151 150
        ent_set_origin(gunner_get_x(shooter1)-ent_get_XLength()/2.0,
152 151
                       gunner_get_y(shooter1)-ent_get_YLength()/2.0);
......
180 179
                            if (i == 0) {
181 180
                                if (no_interrupts % refresh_count_value == 0) {
182 181
                                    update_movement(map1, shooter1);
182
                                    bullet_update_movement(bullet);
183 183

  
184 184
                                    if(map_collides_gunner(map1, shooter1)){
185 185
                                        printf("COLLIDING\n");

Also available in: Unified diff