eco2d/code/game/src/packets/pkt_send_keystate.h

37 lines
1.0 KiB
C
Raw Normal View History

2021-05-05 13:14:02 +00:00
#pragma once
#include "system.h"
#include "packet_utils.h"
typedef struct {
2021-05-08 15:42:47 +00:00
float x;
float y;
2021-08-30 15:50:05 +00:00
float mx;
float my;
2021-05-05 13:14:02 +00:00
uint8_t use;
2021-05-07 20:48:15 +00:00
uint8_t sprint;
2021-08-30 15:50:05 +00:00
uint8_t ctrl;
uint8_t selected_item;
uint8_t drop;
uint8_t swap;
uint8_t swap_from;
uint8_t swap_to;
2021-05-05 13:14:02 +00:00
} pkt_send_keystate;
2021-05-07 14:43:54 +00:00
size_t pkt_send_keystate_send(uint16_t view_id,
2021-05-08 15:42:47 +00:00
float x,
float y,
2021-08-30 15:50:05 +00:00
float mx,
float my,
2021-05-07 20:48:15 +00:00
uint8_t use,
2021-08-30 15:50:05 +00:00
uint8_t sprint,
uint8_t ctrl,
uint8_t drop,
uint8_t selected_item,
uint8_t swap,
uint8_t swap_from,
uint8_t swap_to);
2021-05-05 13:14:02 +00:00
size_t pkt_send_keystate_encode(pkt_send_keystate *table);
2021-05-10 11:27:01 +00:00
extern pkt_desc pkt_send_keystate_desc[];
2021-05-05 13:14:02 +00:00
PKT_HANDLER_PROC(pkt_send_keystate_handler);