Kp
946e7bd4ee
Move some digi symbols to dcx
2016-07-15 03:43:02 +00:00
Kp
74299f7e88
Encourage tail call optimizations in digiobj
2016-07-15 03:43:01 +00:00
Kp
aa95cbfccc
Move set_thrust_from_velocity to dcx
2016-07-15 03:43:01 +00:00
Kp
96f78e1032
Use constexpr for MAX_BITMAP_FILES
2016-07-14 01:59:05 +00:00
Kp
6905b5bd1d
Use constexpr for MAX_SOUNDS
2016-07-14 01:59:04 +00:00
Kp
dcdff564f4
Fold newdemo_record_primary_ammo in draw_hud
2016-07-14 01:59:04 +00:00
Kp
3894c66b9b
Fold do_missile_firing calls to multi_send_fire
2016-07-14 01:59:04 +00:00
Kp
ec19c2ba89
Allow player to grab invulnerability powerup when FakingInvul
...
Previously, if the player was invulnerable, it was impossible to grab an
invulnerability powerup. Relax this by allowing a spawn-induced fake
invulnerability not to count as invulnerable for this test. Players
still cannot grab an invulnerability powerup if they are still under the
influence of a prior invulnerability powerup.
2016-07-14 01:59:04 +00:00
Kp
ed7376c695
Pass object & to update_item_state::process_powerup
2016-07-14 01:59:04 +00:00
Kp
d5a64c4f33
Factor out object count tests
...
An optimizing compiler should inline these tests. Moving them out makes
the code easier to read, since the statements can focus on what is
updated, rather than how it is done.
2016-07-14 01:59:04 +00:00
Kp
663d6df312
Use ?: for MultiLevelInv_CountPlayerInventory flag increment
2016-07-14 01:59:03 +00:00
Kp
023ed08c1c
Switch to vcobjptr for MultiLevelInv_CountPlayerInventory player
...
The index is not needed and the player should not be modified by the
scan.
2016-07-14 01:59:03 +00:00
Kp
e65b93b750
Cache reference to MultiLevelInv.Current
...
Modify MultiLevelInv_CountPlayerInventory to ease conversion to a member
function.
2016-07-14 01:59:03 +00:00
Kp
96d9ae4e4a
Optimize initial MultiLevelInv clear
...
Change the clearing of MultiLevelInv during initialization to reduce
wasted stores. MultiLevelInv has three fields.
Field ::Initial is not accessed by MultiLevelInv_CountLevelPowerups, and
is overwritten immediately afterward, so it does not need to be cleared
first.
Field ::Current is unconditionally cleared by
MultiLevelInv_CountLevelPowerups, so it does not need to be cleared
first.
Field ::RespawnTimer is not accessed by
MultiLevelInv_CountLevelPowerups, but needs to be cleared. Add a clear
of field .RespawnTimer and remove the clear of the entire structure.
2016-07-14 01:59:03 +00:00
Kp
5af44fa27a
Refactor to propagate MultiLevelInv_Count initial
...
All callers of MultiLevelInv_Count passed a constant value. Factor
out the top level blocks of MultiLevelInv_Count into helper functions,
then create two new functions corresponding to MultiLevelInv_Count(0)
and MultiLevelInv_Count(1), implemented by calling the appropriate new
helper functions.
2016-07-14 01:59:03 +00:00
Kp
1d568fa56e
Move MultiLevelInv_Count for vulcan/gauss to use fallthrough
2016-07-14 01:59:03 +00:00
Kp
05db30a6ff
Fix piggy cast when sizeof(size_t) != sizeof(void *)
2016-07-14 01:59:02 +00:00
Kp
39895e5643
Rewrite declarations of ushort *
to standard uint16_t *
2016-07-14 01:59:02 +00:00
Kp
59750d3c29
Rewrite declarations of ubyte *
to standard uint8_t *
2016-07-14 01:59:02 +00:00
Kp
613a7ecbbb
Rewrite parenthesized uses of uint
to standard unsigned
2016-07-14 01:59:02 +00:00
Kp
0b6af7fcbe
Propagate MAX_OBJ_BITMAPS
2016-07-10 04:11:35 +00:00
Kp
ca18195390
Propagate MAX_TEXTURES
2016-07-10 04:11:35 +00:00
Kp
6580c37b6e
Propagate MAX_STOLEN_ITEMS
2016-07-10 04:11:34 +00:00
Kp
71ab00beb8
Propagate MAX_BOSS_TELEPORT_SEGS
2016-07-10 04:11:34 +00:00
Kp
1486a5a01b
Move Robot_sound_volume to dcx
2016-07-09 17:58:36 +00:00
Kp
a63fe62cb3
Add typedef for multi_allow_powerup_text type
2016-07-09 17:58:35 +00:00
Kp
2713baf5d3
Move HUD_MESSAGE_LENGTH to hud.cpp
2016-07-09 17:58:35 +00:00
Kp
7af34fa844
Fold create_n_segment_path calls
2016-07-09 17:58:35 +00:00
Kp
be8022ff41
Add typedef for GMNames array
2016-07-09 17:58:35 +00:00
Kp
3779bc25a0
Define Robot_names only if EDITOR
2016-07-09 17:58:34 +00:00
Kp
fee76e6ced
Define Powerup_names only if EDITOR
2016-07-09 17:58:34 +00:00
Kp
9511ca8aaf
Convert simple multi fix casts from C style to static_cast<>
2016-07-07 03:08:13 +00:00
Kp
a7c64d6f97
Convert simple int casts from C style to static_cast<>
2016-07-07 03:08:13 +00:00
Kp
1dd60cc5be
Rewrite simple fix64 casts from C style to static_cast<>
...
s/(\(fix\(64\)\?\))\s*\(\w\+\);/static_cast<\1>(\3);/g
2016-07-07 03:08:13 +00:00
Kp
9128ff7c35
Move Next_laser_fire_time to player_info
2016-07-06 01:54:26 +00:00
Kp
bd3db75108
Move Next_missile_fire_time to player_info
2016-07-06 01:54:26 +00:00
Kp
a554d7e2c4
Move Next_flare_fire_time into player_info
2016-07-06 01:54:25 +00:00
Kp
6251848c5f
Move Missile_gun into player_info
2016-07-06 01:54:25 +00:00
Kp
6a9ea1a256
Remove unnecessary index tracking in choose_missile_viewer
2016-07-06 01:54:25 +00:00
Kp
a1f67167ce
Use static_cast for check_effect_blowup
2016-07-06 01:54:25 +00:00
Kp
3c71aa812e
Use static_cast for check_trans_wall
2016-07-06 01:54:25 +00:00
Kp
837b46b9b3
Use static_cast for load_mine_data_compiled fix casts
2016-07-06 01:54:25 +00:00
Kp
262094237f
Rewrite simple numeric casts from C style to static_cast<>
...
s/(\(int\|float\|fix\))\s*(/static_cast<\1>(/g
2016-07-06 01:54:24 +00:00
zico
5d2b2891ad
Addition to 32b9202e1f
, making clear_missile_viewer() return if Missile_viewer was set to NULL and only trigger WBU_STATIC in that case, preventing static display when cycling through right cockpit window view
2016-07-04 14:31:30 +02:00
Kp
3fe581c84a
Cache reference to local player object
2016-07-03 00:54:16 +00:00
Kp
3272caed7d
Cache reference to local player energy
2016-07-03 00:54:16 +00:00
Kp
15f2471be0
Cache reference to local player shields
2016-07-03 00:54:16 +00:00
Kp
3b0fccd899
Cache reference to local player secondary ammo
2016-07-03 00:54:15 +00:00
Kp
b9804e6e58
Cache reference to local player cloak time
2016-07-03 00:54:15 +00:00
Kp
c3e2edaff0
Cache reference to local player invulnerable time
2016-07-03 00:54:15 +00:00
Kp
96b258e958
Cache reference to local player flags
2016-07-03 00:54:15 +00:00
Kp
b35a893d9a
Rewrite simple pointer casts from C style to reinterpret_cast<>
...
s/(\s*\(\w\+\s*\*\+\)\s*)\s*(/reinterpret_cast<\1>(/g
2016-07-03 00:54:15 +00:00
Kp
efce2e50dc
Rewrite simple integer casts from C style to static_cast<>
...
s/(\s*\(u\?int[[:digit:]]\+_t\s*\)\s*)\s*(/static_cast<\1>(/g
2016-07-03 00:54:15 +00:00
Kp
f5aed82d83
Rewrite simple pointer casts from C style to reinterpret_cast<>
...
This pass only targets int16_t and uint16_t.
s/(\s*\(u\?int16_t\s*\*\+\)\s*)\s*(/reinterpret_cast<\1>(/g
2016-07-03 00:54:14 +00:00
Kp
19f31eb420
Rewrite simple pointer casts from C style to reinterpret_cast<>
...
This pass only targets int8_t and uint8_t.
s/(\s*\(u\?int8_t\s*\*\+\)\s*)\s*(/reinterpret_cast<\1>(/g
2016-07-03 00:54:14 +00:00
Kp
131b06a7b8
Move & into parentheses
...
s/\()\s*\)&(\([[:alpha:]][[:alnum:].]*\))/\1(\&\2)/g
2016-06-27 04:11:14 +00:00
Kp
3469ff8c34
Change (short*) to (int16_t*)
...
Uses of `(short*)` usually want exactly a 16-bit signed integer. Most
platforms provide that as `short`, but that is not guaranteed.
s/(short \(*\+\)\s*)/(int16_t \1)/g
2016-06-27 04:11:13 +00:00
Kp
a23df63f1b
Change (sbyte *) to (int8_t *)
...
Use the stdint type instead of a Descent custom type.
2016-06-27 04:11:13 +00:00
Kp
6087660944
Add parentheses around casts of array subscripts to pointer types
...
C casts do not require parentheses. C++ casts require grouping around
the target. Prepare for conversion to C++ casts by adding otherwise
unnecessary parentheses around the target of simple C casts.
s/\((\w\+\s*\*\+)\)\s*\(&\w\+\(\[[[:alnum:]+-]*\]\)*[]);]\)/\1(\2)/g
2016-06-27 04:11:13 +00:00
Kp
ce5cce0708
Update delayed weapon when updating primary for grant
...
Grant processing code sets `Primary_weapon` to the user's preferred
weapon, but the delayed autoselect code then changed it back to
something else. Call select_primary_weapon instead of directly updating
`Primary_weapon`, so that `Delayed_primary` is updated too.
This also fixes a bug where the demo always recorded the player
switching to lasers/concussion, instead of the values that the player
actually received from the grant.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/184 >
2016-06-25 23:21:36 +00:00
Kp
a4967ffceb
Move various robot data into namespaces
2016-06-25 23:21:36 +00:00
Kp
a3e65f64ea
Use range_for for polyobj_find_min_max
2016-06-25 23:21:36 +00:00
Kp
89ddc1b911
Add parentheses around casts of simple array subscripts
...
C casts do not require parentheses. C++ casts require grouping around
the target. Prepare for conversion to C++ casts by adding otherwise
unnecessary parentheses around the target of simple C casts.
s/\((\s*\(\(un\)\?signed\|int\|char\|short\|long\|float\|double\|s\?size_t\|\(u\?int[[:digit:]]\+_t\)\)\s*\**\s*)\s*\)\([&+-]\?\)\([[:alnum:]_.]\+\s*->\s*\)*\([[:alnum:]_.]\+\)\(\s*\[[^][]*\]\)*\(\s*\([];+>)*\/^%,|&<>]\)\|$\|\(\s*-\s*[^>]\)\)/\1(\5\6\7\8)\9/g
2016-06-25 23:21:36 +00:00
zico
5c72b57b13
Initialize weapons on new game to prevent spawning with weapons selected in previous game if launching with Granted Weapons
2016-06-20 11:57:31 +02:00
Kp
65f68877aa
Rewrite simple integer casts from C style to static_cast<>
...
This pass only targets commonly used standard types.
s/(\(\s*\(\(un\)\?signed\|int\|char\|short\|long\|float\|double\|s\?size_t\|\(u\?int[[:digit:]]\+_t\)\)\)\s*)\s*(/static_cast<\1>(/g
2016-06-16 03:56:44 +00:00
zico
320b5aa8f0
Fixed regression from bbda32f78d8f227785fe294b5a9786724611d370: Due to GR_FADE_LEVELS being unsigned if statements in draw_player_ship() broke regarding the cloak fade levels. Fixed by some casts.
2016-06-13 14:43:04 +02:00
zico
64f77636a7
When using rapidfire cheat in Descent 1, only grant weapons if cheat toggles on. Also give Rapidfire HUD msg like in Descent II to make clear the state of the cheat. Additional formatting love for lighting debug key to calm GCC's warnings.
2016-06-13 13:24:38 +02:00
Kp
1b12a3f7ef
Add parentheses around target of more complicated casts
...
C casts do not require parentheses. C++ casts require grouping around
the target. Prepare for conversion to C++ casts by adding otherwise
unnecessary parentheses around the target of some C casts.
This pass attempts to process expressions that involve parenthesized or
bracketed subexpressions, but only if those subexpressions do not
themselves contain parenthesized or bracketed subexpressions.
(int) f(1); // changed
(int) f(g()); // not changed
perl -p -i -e 's/(\(\s*((?:un)?signed|int|char|short|long|float|double|s?size_t|(?:u?int[[:digit:]]+_t))\s*\**\s*\)\s*)([&+-]?)([[:alnum:]_.]+\s*->\s*)*([[:alnum:]_.]+)((?:\s*(?:\[[^][]*\])*|(?:\([^()]*\))*))(\s*([;+>*\/^%,|&<>])|$|(\s*-\s*[^>]))/\1\(\3\4\5\6\)\7/g'
2016-06-12 03:45:37 +00:00
Kp
6fc1730770
Convert piggy cast to reinterpret_cast
2016-06-12 03:45:37 +00:00
Kp
bc30ccd216
Rewrite cast of (sbyte) to standard type int8_t
...
s/(sbyte)\s*\(\w\)/(int8_t) \1/g
2016-06-12 03:45:37 +00:00
Kp
478a48ddc1
Fix vulcan ammo object tests
...
Object numbers are unsigned short, not signed short. If anyone ever
raises the object limit high enough, testing for negative values would
blacklist valid objects.
Remove unnecessary test for objnum!=object_none. If it were none,
constructing `obj` would have failed.
2016-06-12 03:45:37 +00:00
Kp
5b437592b0
Simplify test for vulcan|gauss
2016-06-12 03:45:36 +00:00
zico
84f254e2f2
Another addendum to 3366658a5bd2b30a82949b8b301e97b324ce539d: Don't make ngii static anymore (forgot to change this).
2016-06-06 17:29:21 +02:00
zico
7684ce92e4
Added packet to notify clients about a changed vulcan ammo count in a weapon powerup in case player collects ammo but leaves the gun itself.
2016-06-06 17:26:59 +02:00
zico
416ea963c8
When building D2X, before dropping Vulcan ammo check for presence of Gauss cannon, too.
2016-06-06 15:43:38 +02:00
Kp
9283c2f0c3
Improve Error reporting on texmerge consistency failure
2016-06-05 18:45:21 +00:00
Kp
3918db41ff
Factor out common texture merge code
2016-06-05 18:45:20 +00:00
Kp
231223895d
Rewrite simple pointer casts from C style to reinterpret_cast<>
...
This pass only targets commonly used standard types.
s/(\(\s*\(\(un\)\?signed\|int\|char\|short\|long\|float\|double\|s\?size_t\|\(u\?int[[:digit:]]\+_t\)\)\s*\*\)\s*)\s*(/reinterpret_cast<\1>(/g
2016-06-05 01:04:26 +00:00
Kp
b282bea173
Rewrite simple integer casts from C style to static_cast<>
...
This pass only targets commonly used standard types.
s/(\(\s*\(\(un\)\?signed\|int\|char\|short\|long\|float\|double\|s\?size_t\|\(u\?int[[:digit:]]\+_t\)\)\)\s*)\s*(/static_cast<\1>(/g
2016-06-05 01:04:26 +00:00
Kp
ebebda5f17
Fix piggy casts when sizeof(size_t) is not sizeof(void*)
2016-06-05 01:04:26 +00:00
Kp
7fdce88558
Add parentheses around target of simple casts
...
C casts do not require parentheses. C++ casts require grouping around
the target. Prepare for conversion to C++ casts by adding otherwise
unnecessary parentheses around the target of simple C casts.
This pass does not attempt to process expressions that involve
any subexpression that can nest arbitrarily, such as parentheses or
brackets. It also works only on commonly used standard types.
(int) a->b; // changed
(int) a[b]; // not changed
s/\((\s*\(\(un\)\?signed\|int\|char\|short\|long\|float\|double\|s\?size_t\|\(u\?int[[:digit:]]\+_t\)\)\s*\**\s*)\s*\)\([&+-]\?\)\([[:alnum:]_.]\+\s*->\s*\)*\([[:alnum:]_.]\+\)\(\s*\([];+>)*\/^%,|&<>]\)\|$\|\(\s*-\s*[^>]\)\)/\1(\5\6\7)\8/g
2016-06-05 01:04:25 +00:00
Kp
badf0f4f90
Rewrite cast of (uint*) to standard type uint32_t
...
s/(\s*uint\s*\*\s*)/(uint32_t *)/g
2016-06-05 01:04:25 +00:00
Kp
aeebffccc0
Rewrite cast of (ushort*) to standard type uint16_t
...
s/(\s*ushort\s*\*\s*)/(uint16_t *)/g
2016-06-05 01:04:25 +00:00
Kp
b31446340c
Rewrite cast of (ubyte*) to standard type uint8_t
...
s/(\s*ubyte\s*\*\s*)/(uint8_t *)/g
2016-06-05 01:04:25 +00:00
zico
660d18c312
Check for GM_MULTI together with Netgame.InvulAppear in init_player_stats_new_ship(). Otherwise going into Singleplayer after starting a Multiplayer match with this option set can translate this effect into Singleplayer.
2016-05-30 15:00:07 +02:00
zico
e335cdacb3
Reverted 81d7db279b
and rather removed the terminator byte from string length in nm_set_item_input(). This also fixes possible 9 character length for pilot callsigns. Had to fix up COOL_SAYING_LEN as it was not considering the termintor but considering the original D2 source, this was a mess to begin with (def = 50, text string = 60, input field len = 45). Made score saying 50 characters as this seems to be the maximum witdth without overlapping.
2016-05-30 14:54:51 +02:00
zico
1856e73ca6
Addition to 3366658a5bd2b30a82949b8b301e97b324ce539d: Changed show_netgame_info and pass netgame as reference and const; removed struct and extern; declared ngii inside show_netgame_info().
2016-05-30 13:49:06 +02:00
zico
a8ed0aaa9c
Added breaks in event.cpp to prevent unwanted events if -nomouse and/or -nojoystick is given; Added automap_apply_input() to prevent multiple inputs per frame causing multiple movement applications.
2016-05-30 13:17:42 +02:00
Kp
f073e9e377
Fold nm_messagebox call in net_udp_do_join_game
2016-05-28 17:31:27 +00:00
Kp
82a8f6ebb0
Pass bm_mode to gr_init_bitmap
2016-05-28 17:31:27 +00:00
Kp
dcc56e6b39
Propagate bm_mode::linear into iff_read_bitmap
2016-05-28 17:31:27 +00:00
Kp
c00f918a8e
Propagate bm_mode::linear into bald_guy_load
2016-05-28 17:31:26 +00:00
Kp
3fb16c1d7a
Propagate bm_mode::linear into pcx_read_bitmap
2016-05-28 17:31:26 +00:00
Kp
398596c468
Use enum for bitmap mode
2016-05-28 17:31:26 +00:00
Kp
7d468491a1
Fix -Wshadow warnings in mission.cpp
2016-05-22 17:49:32 +00:00
Kp
e3eceb2c6e
Fix -Wshadow warnings in load_mission
2016-05-22 17:49:31 +00:00
Kp
9f76e9e97a
Fix -Wshadow warnings in init_boss_segments
2016-05-22 17:49:31 +00:00
Kp
688b376a90
Fix -Wshadow warnings in write_wall_text
2016-05-22 17:49:30 +00:00
Kp
0cae71b8a6
Fix -Wshadow warnings in draw_model
2016-05-22 17:49:30 +00:00
Kp
994225c188
Use array<> for dumpmine arrays
2016-05-22 17:49:30 +00:00
Kp
f0dcd47b5c
Fold determine_used_textures_level call to load_level
2016-05-22 17:49:30 +00:00
Kp
9d0c6f59a5
Remove always-zero piggy_page_flushed
...
Descent for DOS supported paging content on demand. Rebirth has no
support for paging content out, but retained piggy_page_flushed
to track whether anything had been paged out. Commit 3c20c24
("Disable
piggy_bitmap_page_out_all") removed the last site that could set
piggy_bitmap_page_out_all to a non-zero value. All remaining code
either tests it for non-zero or sets it to zero.
Remove the statements that set it to zero.
Remove assertions that the value is zero.
Remove conditional blocks that execute only when it is non-zero.
2016-05-22 17:49:30 +00:00
Kp
7e3ea961c1
Pass object_base &to draw_player
2016-05-21 17:24:51 +00:00
Kp
c61a3d5e0f
Fix -Wshadow warnings in do_ai_frame
2016-05-21 17:24:51 +00:00
Kp
dbae87a0a1
Fix -Wshadow warnings in load_game_data
2016-05-21 17:24:51 +00:00
Kp
eca671b2f8
Fix -Wshadow warnings in show_netplayerinfo
2016-05-21 17:24:51 +00:00
Kp
f87819b359
Fix -Wshadow warnings in newdemo_strip_frames
2016-05-21 17:24:51 +00:00
Kp
f2f7cb7e96
Fix -Wshadow warnings in newdemo_playback_one_frame
2016-05-21 17:24:51 +00:00
Kp
4a04d26c17
Fix -Wshadow warnings in newdemo_goto_end
2016-05-21 17:24:51 +00:00
Kp
9c4448f78c
Fix -Wshadow warnings in RAIIsocket::closesocket
2016-05-21 17:24:51 +00:00
Kp
6de7046226
Fix -Wshadow warnings in net_udp_setup_game
2016-05-21 17:24:51 +00:00
Kp
6ce7cd4ec5
Fix -Wshadow warnings in draw_player
2016-05-21 17:24:51 +00:00
Kp
ebc9d55b90
Fix -Wshadow warnings in draw_automap
2016-05-21 17:24:51 +00:00
Kp
97f38bf01d
Fix -Wshadow warnings in draw_all_edges
2016-05-21 17:24:51 +00:00
Kp
c7940d12f9
Fix -Wshadow warnings in load_exit_models
2016-05-21 17:24:51 +00:00
Kp
f48247d5c7
Fix -Wshadow warnings in render_compare_context_t
2016-05-21 17:24:51 +00:00
Kp
560401e1ff
Fix -Wshadow warnings in check_face
2016-05-21 17:24:51 +00:00
Kp
213c5952d2
Fix -Wshadow warnings in mark_player_path_to_segment
2016-05-21 17:24:51 +00:00
Kp
989cbb9337
Fix -Wshadow warnings in save_hoard_data
2016-05-21 17:24:51 +00:00
Kp
79c9d19429
Fix -Wshadow warnings in init_hoard_data
2016-05-21 17:24:51 +00:00
Kp
9ab024edc4
Fix -Wshadow warnings in multi_restore_game
2016-05-21 17:24:51 +00:00
Kp
7898353a6c
Fix -Wshadow warnings in multi_disconnect_player
2016-05-21 17:24:51 +00:00
Kp
2dce0cd92d
Fix -Wshadow warnings in newmenu_create_structure
2016-05-21 17:24:51 +00:00
Kp
f3a4a6fef8
Fix -Wshadow warnings in newmenu_mouse
2016-05-21 17:24:50 +00:00
Kp
67cb366c25
Fix -Wshadow warnings in nm_string
2016-05-21 17:24:50 +00:00
Kp
4112f277ff
Remove useless setup of w
in nm_string
2016-05-21 17:24:50 +00:00
Kp
18a917a1d0
Fix -Wshadow warnings in read_model_file
2016-05-21 17:24:50 +00:00
Kp
7f721f98e2
Fix -Wshadow warnings in read_model_guns
2016-05-21 17:24:50 +00:00
Kp
a98e97505e
Fix -Wshadow warnings in do_door_close
2016-05-21 17:24:50 +00:00
Kp
5fb6619fe9
Fix -Wshadow warnings in state_save_all
2016-05-21 17:24:50 +00:00
Kp
36af30b2f6
Fix -Wshadow warnings in state_restore_all_sub
2016-05-21 17:24:50 +00:00
Kp
9b232b71a8
Fix -Wshadow warnings in state_save_all_sub
2016-05-21 17:24:50 +00:00
zico
81d7db279b
Gave input field of Netgame.game_name in net_udp_setup_game() a limit of NETGAME_NAME_LEN as Netgame.game_name.size() would return one byte more for terminator and thus allowing a 16 character game description and nulling mission_title in the process.
2016-05-10 16:16:38 +02:00
zico
1e60e7f31a
Disabled AI behavior switch to toggle AIM_CHASE_OBJECT if in AIB_STILL during a hit, fixing unwanted boss movements and hopefully not breaking anything else
2016-05-10 14:04:30 +02:00
zico
7692d19e2b
Raised default Packets Per Second to 30 and added define for the default in multi.h
2016-05-10 13:45:08 +02:00
zico
3366658a5b
Updated 'Netgame Rules & Info' screen, added option to toggle it ingame via SHIFT-PAUSE, added hint to netgame help menu
2016-05-10 13:41:13 +02:00
Kp
30230a8137
Pass object &to blast_nearby_glass
2016-04-23 17:59:47 +00:00
Kp
a18a483114
Pass object &to bng_process_segment
2016-04-23 17:59:47 +00:00
Kp
d98505354d
Pass object_base &to do_physics_sim_rot
2016-04-23 17:59:47 +00:00
Kp
bde6281e14
Pass object_base &to set_object_turnroll
2016-04-23 17:59:47 +00:00
Kp
99b7c3cf8b
Pass object_base &to do_physics_align_object
2016-04-23 17:59:47 +00:00
Kp
d31f05d89c
Pass object_base &to spin_object
2016-04-23 17:59:47 +00:00
Kp
d3653c92d8
Pass object_base &to start_player_death_sequence
2016-04-23 17:59:47 +00:00
Kp
2188542f2e
Pass object &to set_robot_location_info
2016-04-23 17:59:47 +00:00
Kp
e4d1956674
Pass object_base &to obj_detach_one
2016-04-23 17:59:47 +00:00
Kp
5e734d8f38
Pass object_base &to obj_detach_all
2016-04-23 17:59:47 +00:00
Kp
cfb08ac2cd
Pass object_base &to nd_read_shortpos
2016-04-23 17:59:47 +00:00
Kp
ae7e808a24
Factor out apply_force_damage calls to apply_damage_to_robot
2016-04-23 17:59:47 +00:00
Kp
5f51e4d683
Fix ordering of collide_player_and_controlcen arguments
2016-04-23 17:59:47 +00:00
Kp
8575f3df21
Pass object_base &to my_extract_shortpos
2016-04-23 17:59:47 +00:00
Kp
377effa46d
Pass object_base &to object_allowed_in_anarchy
2016-04-23 17:59:47 +00:00
Kp
56f1729742
Pass object_base &to multi_reset_object_texture
2016-04-23 17:59:47 +00:00
Kp
bfc6efd187
Pass object_base &to compute_headlight_light_on_object
2016-04-23 17:59:47 +00:00
Kp
2401bd60ce
Pass object_base &to homing_missile_turn_towards_velocity
2016-04-23 17:59:47 +00:00
Kp
b46ddf26e7
Pass object &to powerup_grab_cheat
2016-04-23 17:59:47 +00:00
Kp
3677e7036e
Pass object &to collide_player_and_powerup
2016-04-23 17:59:47 +00:00
Kp
752bbedc74
Pass object_base &to explode_model
2016-04-23 17:59:47 +00:00
Kp
841b493387
Pass object_base &to weapon_nearby
2016-04-23 17:59:47 +00:00
Kp
88493aace3
Pass object_base &to object_create_debris
2016-04-23 17:59:47 +00:00
Kp
e51db1c312
Pass object_base &to find_exit_side
2016-04-23 17:59:47 +00:00
Kp
b3d40ff5c4
Pass object_base &to drop_missile_1_or_4
2016-04-23 17:59:47 +00:00
Kp
4153c65f57
Pass object_base &to maybe_drop_primary_weapon_egg
2016-04-23 17:59:47 +00:00
Kp
16583d45db
Pass object_base &to call_object_create_egg
2016-04-23 17:59:47 +00:00
Kp
5682d9f7d7
Simplify boss weapon matter test
2016-04-23 17:59:47 +00:00
Kp
a6ad28c255
Pass object_base &to do_boss_weapon_collision
2016-04-23 17:59:47 +00:00
Kp
ebc0547837
Pass object_base &to boss_spew_robot
2016-04-23 17:59:47 +00:00
Kp
e2fce58d6d
Pass object_base &to collide_robot_and_controlcen
2016-04-23 17:59:47 +00:00
Kp
2fb0e77028
Simplify collide_robot_and_controlcen
...
Caller collide_two_objects swaps the inputs to ensure A.type <= B.type.
OBJ_ROBOT = 2, OBJ_CNTRLCEN = 9, so A will always be the robot and B
will always be the controlcen. Rename the parameters accordingly. Add
assert statements to check this.
2016-04-23 17:59:47 +00:00
Kp
34d2c5b8e2
Pass object_base &to collide_weapon_and_clutter
2016-04-23 17:59:47 +00:00
Kp
a1dac4c254
Pass object_base &to collide_player_and_marker
2016-04-23 17:59:47 +00:00
Kp
5907fec742
Pass object_base &to maybe_delete_object
2016-04-23 17:59:47 +00:00
Kp
a152ef009b
Pass object_base &to maybe_kill_weapon
2016-04-23 17:59:47 +00:00
Kp
7ea89fda9f
Pass object_base &to bump_one_object
2016-04-23 17:59:47 +00:00
Kp
835a9f33d9
Pass object &to collide_robot_and_wall
2016-04-23 17:59:47 +00:00
Kp
389ad4cb1b
Pass object &to calc_controlcen_gun_point
2016-04-23 17:59:47 +00:00
Kp
79edcd0c17
Pass object &to player_path_set_orient_and_vel
2016-04-23 17:59:47 +00:00
Kp
fa1e0d309c
Pass object_base &to add_awareness_event
2016-04-23 17:59:47 +00:00
Kp
49f2768a00
Pass object &to do_firing_stuff
2016-04-23 17:59:47 +00:00
Kp
2a19da88d4
Pass object_base &to move_towards_vector
2016-04-23 17:59:47 +00:00
Kp
a3c5f497f8
Pass object_base &to lead_player
2016-04-23 17:59:47 +00:00
Kp
e6887bb46b
Pass object &to ai_frame_animation
2016-04-23 17:59:47 +00:00
Kp
531725c23f
Factor out ai_frame_animation update
2016-04-23 17:59:47 +00:00
Kp
37a47a4f95
Pass object &to do_silly_animation
2016-04-23 17:59:47 +00:00
Kp
bf69d7c715
Factor out animation angle update
2016-04-23 17:59:47 +00:00
Kp
730d61a738
Pass object &to init_ai_object
2016-04-23 17:59:47 +00:00
Kp
11cf93a299
Factor out net_udp_listen read loop
2016-04-23 17:59:47 +00:00
Kp
271146e84f
Factor out net_udp_flush loop
2016-04-23 17:59:46 +00:00
Kp
fc3e488d81
Remove unnecessary write in RAIIsocket::reset
2016-04-23 17:59:46 +00:00
Kp
bc2c77ba67
Lift weapon1 check in ai_do_actual_firing_stuff
2016-04-17 00:58:44 +00:00
Kp
aad313c85d
Pass object_base &to calc_gun_point
2016-04-09 21:40:27 +00:00
Kp
cc4c07185d
Combine calls to Laser_create_new_easy
2016-04-09 21:40:27 +00:00
Kp
bce267f82f
Pass object_base &to ai_turn_randomly
2016-04-09 21:40:27 +00:00
Kp
c5f933b462
Pass object_base &to ai_turn_towards_vector
2016-04-09 21:40:27 +00:00
Kp
d3b8779cc7
Use PMF helper for lead_player
2016-04-09 21:40:27 +00:00
Kp
95edd77019
Use array<> for ai.cpp globals
2016-04-09 21:40:27 +00:00
Kp
1b65f334cc
Compact multi_do_robot_fire
2016-04-09 21:40:27 +00:00
Kp
5235f813cd
Fold ai_multi_send_robot_position calls
2016-04-06 03:34:15 +00:00
Kp
4126c6c910
Pass object &to multi_send_robot_position
2016-04-06 03:34:15 +00:00
Kp
0e085e4799
Pass thief ID to recreate_thief
2016-04-06 03:34:15 +00:00
Kp
6e0e286dc8
Pass object &to start_robot_death_sequence
2016-04-06 03:34:15 +00:00