Stuffs a players firing information into a packet
| 3292 | |
| 3293 | // Stuffs a players firing information into a packet |
| 3294 | int MultiStuffPlayerFire(int slot, uint8_t *data) { |
| 3295 | int size_offset; |
| 3296 | int count = 0; |
| 3297 | |
| 3298 | size_offset = START_DATA(MP_PLAYER_FIRE, data, &count); |
| 3299 | MultiAddByte(slot, data, &count); |
| 3300 | MultiAddByte(Player_fire_packet[slot].wb_index, data, &count); |
| 3301 | MultiAddByte(Player_fire_packet[slot].fire_mask, data, &count); |
| 3302 | MultiAddByte(Player_fire_packet[slot].damage_scalar, data, &count); |
| 3303 | MultiAddByte(Player_fire_packet[slot].reliable, data, &count); |
| 3304 | |
| 3305 | END_DATA(count, data, size_offset); |
| 3306 | |
| 3307 | return count; |
| 3308 | } |
| 3309 | |
| 3310 | // Returns true if there is enough ammo to allow this player to fire, else false |
| 3311 | bool MultiEnoughAmmoToFire(int slot, int wb_index) { |
no test coverage detected