Kp
44592ddc31
Flatten kconfig type hierarchy
2016-07-14 01:59:05 +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
6554b96b66
Remove unused SWAPINT64
2016-07-14 01:59:04 +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
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
5070f0f0ec
Propagate MAX_INSTANCE_DEPTH
2016-07-10 04:11:34 +00:00
Kp
e2b28eafcc
Use range_for for _rle_expand_texture
2016-07-10 04:11:34 +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
e8d5992797
Remove unused CENTER_STRING_LENGTH
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
0bed5d4727
Rewrite simple HMIDIOUT casts from C style to reinterpret_cast<>
...
s/(\(HMIDIOUT\))(/reinterpret_cast<\1>(/g
2016-07-08 04:14:59 +00:00
Kp
95d3a9d31c
Rewrite simple DWORD casts from C style to static_cast<>
...
s/(\(DWORD\))(/static_cast<\1>(/g
2016-07-08 04:14:59 +00:00
Kp
c8e8c568ff
Add parentheses around target of simple HMIDIOUT
casts
...
s/(\s*HMIDIOUT\s*)\s*\([&+-]\?\)\([[:alnum:]_.]\+\s*->\s*\)*\([[:alnum:]_.]\+\)\(\s*\([];+>)*\/^%,|&<>]\)\|$\|\(\s*-\s*[^>]\)\)/(HMIDIOUT)(\1\2\3)\4/g
2016-07-08 04:14:58 +00:00
Kp
2bc994e673
Add parentheses around target of simple DWORD
casts
...
s/(\s*DWORD\s*)\s*\([&+-]\?\)\([[:alnum:]_.]\+\s*->\s*\)*\([[:alnum:]_.]\+\)\(\s*\([];+>)*\/^%,|&<>]\)\|$\|\(\s*-\s*[^>]\)\)/(DWORD)(\1\2\3)\4/g
2016-07-08 04:14:58 +00:00
Kp
59fb7fa4cb
Convert hmp casts from C style to reinterpret_cast<>
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
b6fd8572d1
Simplify ui_radio_set_value loop
2016-07-06 01:54:25 +00:00
Kp
e92a7aea14
Use C++ static_cast for gadget downcast
2016-07-06 01:54:25 +00:00
Kp
37d6a652c9
Remove useless casts in box.cpp
2016-07-06 01:54:24 +00:00
Kp
d32afbdac5
Rewrite simple unsigned int casts from C style to static_cast<>
...
s/(unsigned int)\s*(/static_cast<uint32_t>(/g
2016-07-06 01:54:24 +00:00
Kp
b0a2205a4e
Convert various pointer casts to reinterpret_cast
2016-07-06 01:54:24 +00:00
Kp
275355994d
Remove useless scanline casts
2016-07-06 01:54:24 +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
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
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
a7ceee3c03
Add parentheses around target of simple unsigned char
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.
s/(\s*unsigned\s\+char\s*\(\*\+\)\s*)\s*\([&+-]\?\)\([[:alnum:]_.]\+\s*->\s*\)*\([[:alnum:]_.]\+\)\(\s*\([];+>)*\/^%,|&<>]\)\|$\|\(\s*-\s*[^>]\)\)/(uint8_t \1)(\2\3\4)\5/g
2016-07-03 00:54:14 +00:00
Kp
c7953a3df1
Fix Win32 use of static_cast where reinterpret_cast is needed
2016-07-02 02:04:11 +00:00
Kp
a24dffad13
Include dsx-ns.h in inferno.h for #define dsx
2016-07-02 02:04:11 +00:00
Kp
a4967ffceb
Move various robot data into namespaces
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
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
Kp
0cb099c5e4
Add parentheses around casts of simple function calls
...
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.
Exclude float|double from the second substitution. Including it
rewrites medmisc.cpp in an incorrect way, and excluding it does not
exclude any valid rewrites.
s/(\(int\|signed\|float\|double\|long\|short\|unsigned\))\s*\(\w\+\s*(\s*\w\+\s*)\)/(\1)(\2)/
s/(\((\(int\|signed\|long\|short\|unsigned\))(\w\+\s*(\s*\w\+\s*))\))/\1/g
2016-06-16 03:56:44 +00: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
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
17d71ee0ae
Rewrite cast of (uint) to standard type uint32_t
...
s/(uint)\s*\(\w\)/(uint32_t) \1/g
2016-06-12 03:45:37 +00: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
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
4324ed3771
Fix scanline 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
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
Kp
73b7905125
Fix -Wshadow warning in get_event (Windows only)
...
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00:00
Kp
86b5427906
Fix -Wshadow warning in visited_segment_multibit_array_t::bitproxy_t
...
bitproxy_t inherits a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00:00
Kp
eea74aefb7
Fix -Wshadow warning in visited_segment_multibit_array_t::tmpl_multibit_proxy_t
...
tmpl_multibit_proxy_t inherits a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00:00
Kp
0cdc1dea72
Fix -Wshadow warning in visited_segment_mask_t::tmpl_maskproxy_t
...
tmpl_maskproxy_t inherits a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00:00
Kp
359f6f58ee
Fix -Wshadow warning in visited_segment_bitarray_t::bitproxy_t
...
bitproxy_t inherits a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00:00
Kp
aa4ad79fbe
Fix -Wshadow warning in visited_segment_bitarray_t::tmpl_bitproxy_t
...
tmpl_bitproxy_t inherits a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/200 >
2016-06-01 01:52:45 +00: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
487547050b
Fix -Wshadow warning in visited_segment_mask_t::base_maskproxy_t
...
base_maskproxy_t has a method named `shift` and its constructor took a
parameter named `shift`. This is unambiguous in the language, but causes
a warning from gcc's -Wshadow in gcc before 5.x. Rename the parameter
to eliminate the warning.
Reported-by: derhass <https://github.com/dxx-rebirth/dxx-rebirth/issues/197 >
2016-05-29 17:46:32 +00:00
Kp
82a8f6ebb0
Pass bm_mode to gr_init_bitmap
2016-05-28 17:31:27 +00:00
Kp
3c5add9d0e
Pass bm_mode to gr_init_bitmap_alloc
2016-05-28 17:31:27 +00:00
Kp
86122120b7
Pass bm_mode to gr_init_canvas
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
a0cc2bfc7e
Pass canvas to ogl_upixelc
2016-05-28 17:31:26 +00:00
Kp
2dfd87f276
Move OGL_VIEWPORT assignments above glViewport
2016-05-28 17:31:26 +00:00
Kp
4a3abb3ca3
Cache src values in gr_ubitmap00
2016-05-28 17:31:26 +00:00
Kp
bbda32f78d
Make cv_fade_level unsigned
2016-05-28 17:31:26 +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
1551443eff
Fix -Wshadow warnings in macro check_warn_object_type
2016-05-21 17:24:51 +00:00
zico
64400ff284
Restored original Descent 2 HOMING_MAX_TRACKABLE_DOT for D2X build, formerly using the Descent 1 setting
2016-05-10 14:22:53 +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
3677e7036e
Pass object &to collide_player_and_powerup
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
ebc0547837
Pass object_base &to boss_spew_robot
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
389ad4cb1b
Pass object &to calc_controlcen_gun_point
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
aad313c85d
Pass object_base &to calc_gun_point
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
95edd77019
Use array<> for ai.cpp globals
2016-04-09 21:40:27 +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
Kp
0c299248d4
Pass object &to apply_damage_to_player
2016-04-06 03:34:14 +00:00
Kp
72aa4bc8fb
Pass object &to phys_apply_rot
2016-04-06 03:34:14 +00:00
Kp
bad1464dcf
Pass object_base &to physics_turn_towards_vector
2016-04-06 03:34:14 +00:00
Kp
6a1e1670cc
Pass object_base &to phys_apply_force
2016-04-06 03:34:14 +00:00
Kp
afa8ffffa3
Remove obsolete bits from GM_MULTI
2016-04-06 03:34:14 +00:00
Kp
89eb173013
Move draw_object_blob to namespace dcx
2016-04-06 03:34:14 +00:00
Kp
c2905bda23
Move check_warn_object_type to namespace dcx
2016-04-06 03:34:13 +00:00
Kp
608467161b
Remove obsolete arguments from DEFINE_VALPTRIDX_SUBTYPE
2016-04-06 03:34:13 +00:00
Kp
443b1f2915
Add file/line to valptridx output when available
2016-04-06 03:34:13 +00:00
Kp
5b3a36e6b8
Remove valptridx operator-(P *, A &)
2016-04-06 03:34:13 +00:00
Kp
ae722cbb8b
Shorten maybe_send_z_move
2016-04-03 17:50:42 +00:00
Kp
1789643480
Remove UserError on unknown MED function
...
Jayman2000 reports that users who do not update their MED.MNU after
updating to 8b61b9f
("Remove unused symbols") receive an "editor crash"
on startup. This is not a crash, but instead is poor error handling in
menubar.cpp, which calls UserError instead of ignoring the offending
line. Calls to UserError are fatal, but do not crash the program.
Replace that call with a con_printf(CON_URGENT) and ignore the line.
Additionally, change the handling for excess menus and for excess menu
items to con_printf+ignore instead of UserError.
Reported-by: Jayman2000 <https://github.com/dxx-rebirth/dxx-rebirth/pull/190 >
Fixes: 8b61b9f0db
("Remove unused symbols")
2016-04-03 17:50:42 +00:00
Kp
fb6db67d94
Include file+line in UserError output
2016-04-03 17:50:42 +00:00
zico
ab89dcd366
Reworked 586ba9ff6db85b976f074589c5dd7e2d6ff40cd1: Show player ping along with player kills/scores and made it a toggle for HUD configuration so the player can enable it permanently
2016-03-30 20:09:46 +02:00
Kp
dd3cedff3d
Add get_ghost_id for multi_do_reappear
...
Ghosts use the same ID space as players, so reuse function get_player_id
to fetch the ID after checking.
Reported-by: zicodxx <https://github.com/dxx-rebirth/dxx-rebirth/issues/182 >
Fixes: 9f26e2211e
("Warn on invalid object ID access")
2016-03-20 20:38:54 +00:00
Kp
27cef20eb3
Move namespace dsx handling to dsx-ns.h
2016-03-19 19:08:10 +00:00
Kp
b8f39b024a
Move DoMenu into dsx
2016-03-19 19:08:10 +00:00
Kp
797c8b47b2
Move segment_object_iterator_t into segment_object_range_t
2016-03-19 19:08:10 +00:00
Kp
97219697a7
Make check_warn_object_type work without gcc ({}) extension
2016-03-05 17:26:24 +00:00
zico
36d22a3998
Added more specific comment on why RespawnTimer is necessary for MultiLevelInv_Repopulate()
2016-02-29 16:35:00 +01:00
Kp
95ab6076a4
Move FakingInvul to player_info
...
Every player can fake invulnerability independently. In preparation for
host tracking, store FakingInvul as a player property, not a static
global.
2016-02-27 19:02:21 +00:00
zico
901a554e96
New powerup management code: Addeed functions and packet type to keep track of original and current level inventory as well as player and thief inventories. Calling maybe_drop_net_powerup() for all ammo based weapons except Concussion missiles. Limiting maybe_drop_net_powerup() to only spawn items missing from initial level inventory. Added function to let host respawn items that were lost for whatever reason. Expanded maybe_drop_net_powerup() and child functions to be able to drop item based on a random player. Changed back maybe_drop_secondary_weapon_egg() to its original behavior, dropping 3 of each type max.
2016-02-25 14:11:08 +01:00
Kp
c3003fbb22
Fix vulcan ammo display
...
Do not abuse `f2i` to shift an unsigned quantity. `f2i` is defined to
work on `fix`, which is `int`.
2016-02-20 17:28:11 +00:00
Kp
3c20c24ac0
Disable piggy_bitmap_page_out_all
2016-02-20 17:28:11 +00:00
Kp
1a4290002e
Revert partial_const_range for HMP get_event
...
Fixes: b57f08c798
("Use partial_const_range")
2016-02-17 03:34:30 +00:00
Kp
08de1bbff0
Remove cv_color
...
It is only ever set to 0 or copied from other canvases. Set it to zero
everywhere.
2016-02-12 04:02:28 +00:00
Kp
f4e1ebb576
Remove unnecessary gr_setcolor calls
2016-02-12 04:02:28 +00:00
Kp
e09a590e6f
Pass color to Vline
2016-02-12 04:02:28 +00:00
Kp
76d0e01b6e
Pass color to Hline
2016-02-12 04:02:28 +00:00
Kp
d08bfc3170
Pass color to g3_draw_sphere
2016-02-12 04:02:28 +00:00
Kp
1b4b6673ee
Pass color to g3_draw_poly
2016-02-12 04:02:28 +00:00
Kp
a98d553f3e
Pass color to must_clip_flat_face
2016-02-12 04:02:28 +00:00
Kp
8c24eaa721
Pass color to g3_draw_line
2016-02-12 04:02:28 +00:00
Kp
6b9a03cf2d
Pass color to gr_upoly_tmap
2016-02-12 04:02:28 +00:00
Kp
61821d0b42
Pass color to gr_upoly_tmap_ylr
2016-02-12 04:02:28 +00:00
Kp
36bd39babe
Pass color to gr_line
2016-02-12 04:02:28 +00:00
Kp
3c73d44771
Pass color to gr_disk
2016-02-12 04:02:28 +00:00
Kp
ecb71ba22e
Pass color to gr_ucircle
2016-02-12 04:02:28 +00:00
Kp
edd2acc86b
Pass color to gr_box
2016-02-12 04:02:28 +00:00
Kp
8135577315
Pass color to gr_ubox12
2016-02-12 04:02:28 +00:00
Kp
de08a67321
Pass color to gr_ubox
2016-02-12 04:02:28 +00:00
Kp
23047b1165
Pass color to gr_rect
2016-02-12 04:02:28 +00:00
Kp
35a4736df0
Pass color to gr_urect
2016-02-12 04:02:28 +00:00
Kp
f235d6b12b
Pass color to gr_pixel
2016-02-12 04:02:28 +00:00
Kp
053901b62b
Pass color to gr_uline
2016-02-12 04:02:28 +00:00
Kp
5aeb7559fb
Pass color to 2d/line.cpp workers
2016-02-12 04:02:28 +00:00
Kp
659f0fb3ab
Pass color to gr_upixel
2016-02-12 04:02:28 +00:00
Kp
0dcfa6fba5
Pass color to ogl_urect
2016-02-12 04:02:28 +00:00
Kp
fabe774291
Pass color to gr_scanline
2016-02-12 04:02:28 +00:00
Kp
8e186e93e2
Unify g3_draw_sphere must_clip_line paths
2016-02-12 04:02:28 +00:00
Kp
1c04cb70d9
Change ogl_ubitmapm_cs constant -1 to const white
2016-02-12 04:02:28 +00:00
Kp
2a50243a07
Separate out ogl_ubitmapm_cs color setup
2016-02-12 04:02:28 +00:00
Kp
553b313099
Use vwallptr
2016-02-12 04:02:28 +00:00
Kp
2fd6a425b0
Remove highest_valid
2016-02-12 04:02:28 +00:00
Kp
e07c9a5f87
Combine ft_chars, ft_allocdata into one allocation
2016-02-12 04:02:28 +00:00
Kp
230f2dbb19
Make cv_blend_func OGL-specific
2016-02-12 04:02:28 +00:00
Kp
b57f08c798
Use partial_const_range
2016-02-12 04:02:28 +00:00
Kp
0f700eec0b
Unify g3_draw_sphere calls to gr_disk
2016-02-11 03:25:52 +00:00
Kp
455ab60c4a
Switch OGL extension include to <SDL.h>
...
The new OGL extension code included <SDL/SDL.h>, which works when the
SDL headers are installed in a directory named SDL and that directory is
in a system search directory. Those conditions usually hold on Linux,
both for /usr/include and /usr/local/include. However, non-Linux users
sometimes install SDL in other places. Kreator reports that the OGL
build on OS X failed because his SDL headers were on the search path,
but not in a directory named SDL on the search path. Switch the
include directive to an unqualified name to match other SDL includes.
Reported-by: kreatordxx <private mail>
Fixes: db267af6f2
("add basic OpenGL extension handling")
2016-02-11 03:25:52 +00:00
Kp
8a324f8492
Simplify gr_scanline
2016-02-10 03:58:05 +00:00
Kp
443b021db8
Precompute fade_table first level index
2016-02-10 03:58:05 +00:00
Kp
e6d5b6f041
Move valptridx get_count/set_count to untyped base
2016-02-10 03:58:05 +00:00
Kp
c5f4daa11b
Remove write-only trigger field time
2016-02-06 22:12:55 +00:00
Kp
6e20d86941
Move OF_PLAYER_DROPPED into drop_powerup
...
This fixes an issue where calling drop_powerup with num > 1 only tagged
one powerup as player-dropped.
This also changes powerups dropped by the thief to be "player-dropped",
since, aside from the initial shields/energy, they came from the player
originally.
2016-02-06 22:12:55 +00:00
Kp
1f9e69b0b7
Replace highest_valid(V,offset) with partial_range
2016-02-06 22:12:55 +00:00
Kp
96a183e3d2
Move partial_range __builtin_object_size out of line
2016-02-06 22:12:55 +00:00
Kp
69b7693720
Propagate partial_range size up
2016-02-06 22:12:55 +00:00
Kp
92e6987c2c
Improve exact_type comparison operators
2016-02-06 22:12:54 +00:00
Kp
198540d080
Use range_for in bm.cpp
2016-02-06 22:12:54 +00:00
Kp
ec025d4e88
Pass common highest_valid to vptr factory
2016-02-06 22:12:54 +00:00
Kp
0101f98905
Use wallnum_t in more places
2016-02-06 22:12:54 +00:00
Kp
bb5d1bb7e5
Use valptridx array type for Walls
2016-02-06 22:12:54 +00:00
Kp
72d2844070
Use enum for trigger flags
2016-02-06 22:12:54 +00:00
Kp
74dfa29d31
Convert most Trigger references to valptridx
2016-02-06 22:12:54 +00:00
Kp
4f0cbcffa9
Use valptridx array type for Triggers
2016-02-06 22:12:53 +00:00
Kp
5f33054161
Hide vm_distance safety net from clang
...
When the safety net is present, clang becomes confused. Run without a
net and hope that gcc users catch any erroneous conversions.
2016-02-02 03:10:53 +00:00
Kp
e283a22709
Use enum class for check_volatile_wall
2016-01-29 04:05:47 +00:00
Kp
bc488a8f57
Improve check_volatile_wall
2016-01-29 04:05:47 +00:00
Kp
386a58e3f6
Simplify make_range
2016-01-29 04:05:47 +00:00
Kp
905d935a6b
Remove write-only cv_drawmode
2016-01-29 04:05:47 +00:00
Kp
ff67afd440
Propagate partial_range up into PHYSFSX_findFiles family
2016-01-29 04:05:47 +00:00
Kp
4abbc28d0f
Switch to non-template operator> for vm_distance
...
clang considers the template form to be ambiguous
2016-01-27 04:01:55 +00:00
Kp
5a1791f7c3
Fix valptridx pch build
2016-01-26 03:45:08 +00:00
Kp
bad07b668e
Fix misplaced preprocessor directive
2016-01-26 03:45:06 +00:00
Kp
4e29e2625d
Move multi_endlevel_poll* lookups to menu creation
2016-01-26 03:45:06 +00:00
Kp
124a2ee09c
Move net_udp.cpp specific defines out of header
2016-01-26 03:45:06 +00:00
Kp
8f7d323ec6
Fix clang cvar build
...
Add format(printf,...) annotation to varargs functions to move format
string checking up one level.
2016-01-26 03:45:06 +00:00
Kp
9e174a0e0e
Factor out primary/secondary search/reorder
2016-01-17 17:36:48 +00:00
Kp
677c70c64e
Move font filename into grs_font
2016-01-10 21:18:09 +00:00
Kp
5d4fff1534
Combine gr_printf/gr_uprintf into template
2016-01-10 21:18:08 +00:00
Kp
7386094bc3
Rename menu macros to reduce token pasting
2016-01-09 16:38:17 +00:00
Kp
eb3fe7acdb
Remove sprintf from menubar.cpp
2016-01-09 16:38:16 +00:00
Kp
110d62a748
Remove sprintf from autosave.cpp
2016-01-09 16:38:16 +00:00
Kp
dd877f52c2
Remove unused weapon defines
2016-01-09 16:38:15 +00:00
Kp
8e86a3586d
Use #ifdef dsx to guard dsx namespace
2016-01-09 16:38:15 +00:00
Kp
86709f547b
Fix capitalization of PHYSFS_File
...
Per comment in physfs.h, the spelling PHYSFS_file is deprecated.
Replace all instances with PHYSFS_File.
2016-01-09 16:38:14 +00:00
Kp
a3ae630829
Remove default argument for basic_ptridx(index)
2016-01-09 16:38:14 +00:00
Kp
9ceedc96a8
Propagate valptridx requirement up
2016-01-09 16:38:14 +00:00
Kp
0be0475309
Move valptridx array highest to base class
2016-01-09 16:38:14 +00:00
Kp
6489c64598
Use type_traits to manage valptridx const
2016-01-09 16:38:13 +00:00
Kp
d6359d0eb7
Use template for object rotation functions
2016-01-09 16:38:13 +00:00
Kp
a32d9f01a1
Remove return value truncation in find_object_seg
2016-01-09 16:38:13 +00:00
Kp
98f5afa9f8
Remove default argument for basic_ptr(pointer,array &)
2016-01-09 16:38:13 +00:00
Kp
d17b12da31
Remove default argument for basic_ptr(index,array &)
2016-01-09 16:38:12 +00:00
Kp
1cef946a90
Remove default argument for basic_idx(index,array &)
2016-01-09 16:38:12 +00:00
Kp
96898bab0a
Block direct changes to Highest_segment_index
...
Route updates through helper functions.
2016-01-09 16:38:12 +00:00
Kp
f48eddeece
Block direct changes to Highest_object_index
...
Route updates through helper functions.
2016-01-09 16:38:12 +00:00
Kp
5a94f8bf4f
Fix check_header_includes build
2016-01-09 16:38:12 +00:00
Kp
1f91897f5d
Move some game symbols to namespaces
2016-01-09 16:38:12 +00:00
Kp
568f165c28
Shrink sincos_table
...
For all valid i, sincos_table[i] == sincos_table[i % 256]. Remove
elements [256:] and modify callers to truncate the index.
2016-01-09 16:38:11 +00:00
Kp
0a68a6439e
Use ={} to clear rle cache
2016-01-09 16:38:11 +00:00
Kp
fe1c0ee59b
Remove unnecessary free_text
...
The text is stored in a global unique_ptr, so running global destructors
will free the text.
2016-01-09 16:38:11 +00:00
Kp
0635dbf108
Pass trigger &
2016-01-09 16:38:11 +00:00
Kp
16c754f3a2
Split key_toggle_repeat paths at compile time
...
Every caller passes a literal truth value. Split the implementation by
the truth value. This saves loading the value before the call and
testing it inside the call.
2016-01-09 16:38:10 +00:00
Kp
410b09a330
Expand macro Player_exploded
2016-01-09 16:38:10 +00:00
Kp
47190be8e9
Fold Player_exploded into Player_dead_state
2016-01-09 16:38:10 +00:00
Kp
608cfdbf07
Combine Mission::enhanced with Mission::descent_version
2016-01-09 16:38:09 +00:00
Kp
24e902d4cf
Simplify find_connect_side
2016-01-03 20:21:35 +00:00
Kp
3428ea6392
Remove Show_only_curside
...
Show_only_curside was locked to 0 in EDITOR builds, but only EDITOR
builds could render the current side.
2016-01-03 20:21:35 +00:00
Kp
823ff63126
Move MplTrackerAddr to CArg
2015-12-24 04:01:29 +00:00
Kp
0b87ff267f
Move MplTrackerPort to CArg
2015-12-24 04:01:29 +00:00
Kp
3f9f1f2b49
Move MplUdpMyPort to CArg
2015-12-24 04:01:29 +00:00
Kp
56e77d4fec
Move MplUdpHostPort to CArg
2015-12-24 04:01:28 +00:00
Kp
0fb84b883f
Move DbgAltTex to CArg
2015-12-24 04:01:28 +00:00
Kp
b0e0f48058
Move DbgTexMap to CArg
2015-12-24 04:01:28 +00:00
Kp
a91ef00a86
Move DbgNoCompressPigBitmap to CArg
2015-12-24 04:01:28 +00:00
Kp
96b9f606d7
Invert game_render_frame_mono argument
2015-12-24 04:01:28 +00:00
Kp
834258fffa
Move DbgNoDoubleBuffer to CArg
2015-12-24 04:01:28 +00:00
Kp
048615f95e
Move DbgRenderStats to CArg
2015-12-24 04:01:28 +00:00
Kp
45a287f44b
Move DbgNoRun to CArg
2015-12-24 04:01:28 +00:00
Kp
ee98ef18f3
Move DbgSdlASyncBlit to CArg
2015-12-24 04:01:28 +00:00
Kp
94616f5e1c
Move DbgSdlHWSurface to CArg
2015-12-24 04:01:27 +00:00
Kp
4f14be6056
Move MplUdpHostAddr to CArg
2015-12-24 04:01:27 +00:00
Kp
2c3f64478d
Move OglSyncWait to CArg
2015-12-24 04:01:27 +00:00
Kp
9ec7e766cf
Move OglSyncMethod to CArg
2015-12-24 04:01:27 +00:00
Kp
d7c694b126
Move OglFixedFont to CArg
2015-12-24 04:01:27 +00:00
Kp
679e0adf3d
Move SysAutoDemo to CArg
2015-12-24 04:01:27 +00:00
Kp
cbd2cd7c54
Move SysNoTitles to CArg
2015-12-24 04:01:27 +00:00
Kp
948fa32f9c
Move SysNoBorders to CArg
2015-12-24 04:01:27 +00:00
Kp
4ac7055928
Move SysWindow to CArg
2015-12-24 04:01:27 +00:00
Kp
2629b5b3d9
Move SysAutoRecordDemo to CArg
2015-12-24 04:01:27 +00:00
Kp
93f3162a41
Move SysLowMem to CArg
2015-12-24 04:01:26 +00:00
Kp
2b4447f927
Move SysUsePlayersDir to CArg
2015-12-24 04:01:26 +00:00
Kp
2cea05d0a7
Move SysRecordDemoNameTemplate to CArg
2015-12-24 04:01:26 +00:00
Kp
63cd2dbb6b
Move SysPilot to CArg
2015-12-24 04:01:26 +00:00
Kp
584e2ce408
Move SysHogDir to CArg
2015-12-24 04:01:26 +00:00
Kp
9f1abe1910
Move SndNoMusic to CArg
2015-12-24 04:01:26 +00:00
Kp
bb3a386b47
Move GfxSkipHiresFNT to CArg
2015-12-24 04:01:26 +00:00
Kp
23bb4c5826
Move SysNoNiceFPS to CArg
2015-12-24 04:01:26 +00:00
Kp
63369b4dec
Shrink DbgVerbose to int8_t
...
Valid values are in [-3, 2].
2015-12-24 04:01:26 +00:00
Kp
fd53bb3738
Move #include <signal.h> out of namespace dcx
...
Reported-by: derhass <https://github.com/dxx-rebirth/dxx-rebirth/issues/170 >
2015-12-23 03:28:17 +00:00
Kp
be04d3a4f9
Rewrite CLI
...
Remove artificial length limit on input.
Enable multi-line display of input.
2015-12-22 04:18:52 +00:00
Kp
287a74f88b
Multiplex do_laser_firing_player flags
2015-12-22 04:18:52 +00:00
Kp
f4a5040a60
Remove write-only Last_laser_fired_time
2015-12-22 04:18:52 +00:00
Kp
e8c34be843
Use v*ptr* factories with highest_valid
2015-12-22 04:18:51 +00:00
Kp
d479819931
Use absolute_sibling to reduce global references for ptridx
2015-12-22 04:18:51 +00:00
Kp
5d4bcddd4f
Move common object fields to dcx::object_base
2015-12-22 04:18:50 +00:00