|
Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
|
|
#include "pong.qh"Go to the source code of this file.
Functions | |
| vector | box_nearest (vector box_min, vector box_max, vector p) |
| void | pong_add_score (entity minigame, int team_thrower, int team_receiver, int delta) |
| entity | pong_ai_spawn (entity paddle) |
| void | pong_ai_think (entity this) |
| void | pong_ball_reset (entity ball) |
| void | pong_ball_think (entity this) |
| void | pong_ball_throw (entity ball) |
| void | pong_ball_throwthink (entity this) |
| bool | pong_goal (entity ball, int pteam) |
| void | pong_paddle_bounce (entity ball, int pteam) |
| bool | pong_paddle_hit (entity ball, int pteam) |
| entity | pong_paddle_spawn (entity minigame, int pl_team, entity real_player) |
| void | pong_paddle_think (entity this) |
| int | pong_server_event (entity minigame, string event,...) |
| vector | pong_team_to_box_halfsize (int nteam, float length, float width) |
| vector | pong_team_to_paddlepos (int nteam) |
| REGISTER_MINIGAME (pong, _("Pong")) | |
Variables | |
| float | autocvar_sv_minigames_pong_ai_thinkspeed |
| float | autocvar_sv_minigames_pong_ai_tolerance |
| float | autocvar_sv_minigames_pong_ball_number |
| float | autocvar_sv_minigames_pong_ball_radius |
| float | autocvar_sv_minigames_pong_ball_speed |
| float | autocvar_sv_minigames_pong_ball_wait |
| float | autocvar_sv_minigames_pong_paddle_size |
| float | autocvar_sv_minigames_pong_paddle_speed |
| entity | pong_ai_paddle |
| const int | PONG_KEY_BOTH = 0x03 |
| const int | PONG_KEY_DECREASE = 0x02 |
| const int | PONG_KEY_INCREASE = 0x01 |
| int | pong_keys |
| float | pong_length |
| const int | PONG_MAX_PLAYERS = 4 |
| entity | pong_paddles [PONG_MAX_PLAYERS] |
| int | pong_score |
| const int | PONG_SF_BALLTEAM = MINIG_SF_CUSTOM |
| const int | PONG_SF_PLAYERSCORE = MINIG_SF_CUSTOM |
| const int | PONG_SPECTATOR_TEAM = 255 |
| const int | PONG_STATUS_PLAY = 0x0020 |
| const int | PONG_STATUS_WAIT = 0x0010 |
Definition at line 97 of file pong.qc.
Referenced by pong_paddle_hit().
Definition at line 77 of file pong.qc.
References entity(), and PONG_SF_PLAYERSCORE.
Referenced by pong_goal().
Definition at line 261 of file pong.qc.
References entity(), msle_spawn(), pong_ai_think(), setthink, and time.
Referenced by pong_paddle_spawn(), and pong_server_event().
Definition at line 211 of file pong.qc.
References autocvar_sv_minigames_pong_ai_thinkspeed, autocvar_sv_minigames_pong_ai_tolerance, autocvar_sv_minigames_pong_paddle_speed, entity(), findentity(), nextthink, NULL, owner, pong_ai_paddle, PONG_KEY_DECREASE, PONG_KEY_INCREASE, pong_keys, pong_length, target, team, time, and vlen().
Referenced by pong_ai_spawn().
Definition at line 65 of file pong.qc.
References autocvar_sv_minigames_pong_ball_wait, entity(), MINIG_SF_UPDATE, pong_ball_throwthink(), PONG_SF_BALLTEAM, setthink, SUB_NullThink(), and time.
Referenced by pong_goal(), and pong_server_event().
Definition at line 155 of file pong.qc.
References autocvar_sys_ticrate, entity(), MINIG_SF_UPDATE, nextthink, pong_goal(), pong_length, PONG_MAX_PLAYERS, pong_paddle_bounce(), pong_paddle_hit(), PONG_SF_BALLTEAM, SendFlags, team, and time.
Referenced by pong_ball_throw().
Definition at line 44 of file pong.qc.
References angle, autocvar_sv_minigames_pong_ball_speed, cos(), entity(), fabs(), M_PI, MINIG_SF_UPDATE, pong_ball_think(), PONG_SF_BALLTEAM, random(), setthink, sin(), and time.
Referenced by pong_ball_throwthink().
Definition at line 59 of file pong.qc.
References entity(), and pong_ball_throw().
Referenced by pong_ball_reset().
Definition at line 138 of file pong.qc.
References entity(), pong_add_score(), pong_ball_reset(), and pong_paddle_hit().
Referenced by pong_ball_think().
Definition at line 122 of file pong.qc.
References box_nearest(), boxesoverlap(), entity(), vdist, and vector.
Referenced by pong_ball_think(), and pong_goal().
Definition at line 320 of file pong.qc.
References autocvar_sv_minigames_pong_paddle_size, entity(), msle_spawn(), NULL, pong_ai_spawn(), pong_paddle_think(), pong_team_to_box_halfsize(), pong_team_to_paddlepos(), setthink, and time.
Referenced by pong_server_event().
Definition at line 276 of file pong.qc.
References autocvar_sv_minigames_pong_paddle_speed, autocvar_sys_ticrate, bound(), entity(), MINIG_SF_UPDATE, nextthink, PONG_KEY_DECREASE, PONG_KEY_INCREASE, pong_length, realowner, SendFlags, team, and time.
Referenced by pong_paddle_spawn().
Definition at line 343 of file pong.qc.
References argv(), autocvar_sv_minigames_pong_ball_number, autocvar_sv_minigames_pong_ball_radius, entity(), int, MINIG_SF_UPDATE, MSG_ENTITY, msle_spawn(), NULL, pong_ai_spawn(), pong_ball_reset(), PONG_KEY_DECREASE, PONG_KEY_INCREASE, PONG_MAX_PLAYERS, pong_paddle_spawn(), PONG_SF_PLAYERSCORE, PONG_SPECTATOR_TEAM, PONG_STATUS_PLAY, PONG_STATUS_WAIT, sprint(), stoi, vec2, and WriteLong().
Definition at line 306 of file pong.qc.
References vector.
Referenced by pong_paddle_spawn().
| REGISTER_MINIGAME | ( | pong | , |
| _("Pong") | ) |
| float autocvar_sv_minigames_pong_ai_thinkspeed |
Definition at line 38 of file pong.qc.
Referenced by pong_ai_think().
| float autocvar_sv_minigames_pong_ai_tolerance |
Definition at line 39 of file pong.qc.
Referenced by pong_ai_think().
| float autocvar_sv_minigames_pong_ball_number |
Definition at line 36 of file pong.qc.
Referenced by pong_server_event().
| float autocvar_sv_minigames_pong_ball_radius |
Definition at line 35 of file pong.qc.
Referenced by pong_server_event().
| float autocvar_sv_minigames_pong_ball_speed |
Definition at line 34 of file pong.qc.
Referenced by pong_ball_throw().
| float autocvar_sv_minigames_pong_ball_wait |
Definition at line 33 of file pong.qc.
Referenced by pong_ball_reset().
| float autocvar_sv_minigames_pong_paddle_size |
Definition at line 30 of file pong.qc.
Referenced by pong_paddle_spawn().
| float autocvar_sv_minigames_pong_paddle_speed |
Definition at line 31 of file pong.qc.
Referenced by pong_ai_think(), and pong_paddle_think().
| entity pong_ai_paddle |
Definition at line 26 of file pong.qc.
Referenced by pong_ai_think().
| const int PONG_KEY_DECREASE = 0x02 |
Definition at line 16 of file pong.qc.
Referenced by pong_ai_think(), pong_paddle_think(), and pong_server_event().
| const int PONG_KEY_INCREASE = 0x01 |
Definition at line 15 of file pong.qc.
Referenced by pong_ai_think(), pong_paddle_think(), and pong_server_event().
| int pong_keys |
Definition at line 23 of file pong.qc.
Referenced by pong_ai_think().
| float pong_length |
Definition at line 25 of file pong.qc.
Referenced by pong_ai_think(), pong_ball_think(), and pong_paddle_think().
| const int PONG_MAX_PLAYERS = 4 |
Definition at line 20 of file pong.qc.
Referenced by pong_ball_think(), and pong_server_event().
| entity pong_paddles[PONG_MAX_PLAYERS] |
| const int PONG_SF_BALLTEAM = MINIG_SF_CUSTOM |
Definition at line 12 of file pong.qc.
Referenced by pong_ball_reset(), pong_ball_think(), and pong_ball_throw().
| const int PONG_SF_PLAYERSCORE = MINIG_SF_CUSTOM |
Definition at line 10 of file pong.qc.
Referenced by pong_add_score(), and pong_server_event().
| const int PONG_SPECTATOR_TEAM = 255 |
Definition at line 21 of file pong.qc.
Referenced by pong_server_event().
| const int PONG_STATUS_PLAY = 0x0020 |
Definition at line 6 of file pong.qc.
Referenced by pong_server_event().
| const int PONG_STATUS_WAIT = 0x0010 |
Definition at line 5 of file pong.qc.
Referenced by pong_server_event().