Commit graph

81 commits

Author SHA1 Message Date
Kp 0d564814f5 Convert Primary_weapon to primary_weapon_index_t 2015-04-26 20:15:57 +00:00
Kp 8d849b2b39 Wrap laser level in class
Move enum laser_level_t to weapon.h for the new class.
2015-04-26 20:15:56 +00:00
Kp adbefd39c4 Minimize unnecessary fields passed to check_effect_blowup 2015-04-19 04:18:52 +00:00
Kp c338862ad6 Reduce gauges.h includes 2015-04-19 04:18:51 +00:00
Kp 84c638ed64 Move PHYSFS_list_t to separate header 2015-04-19 04:18:49 +00:00
Kp 6b6eaef226 Include polyobj.h from robot.h
Swap the inclusion order since all robots are polyobjects, but not all
polyobjects are robots.
2015-04-02 02:36:57 +00:00
Kp 2f86499144 Remove do_cockpit_window_view unused parameters 2015-04-02 02:36:57 +00:00
Kp 90fbebf8fd Convert most global arrays to array<> 2015-04-02 02:36:52 +00:00
Kp 91d31b1952 Wrap object signature in subtype 2015-03-22 18:49:21 +00:00
Kp 7bf49fe551 Fix clang -Wmissing-braces warnings 2015-03-22 18:49:21 +00:00
Kp 9ddea5f570 Reduce lifetime of Args 2015-03-22 18:49:20 +00:00
Kp 2c09f9fa90 Propagate special types for distance/magnitude 2015-03-12 02:21:19 +00:00
Kp 0684444765 Fix Windows build
Fixes: 07869d9dba ("Add automatic demo recording")
2015-02-28 22:34:07 +00:00
Kp 07869d9dba Add automatic demo recording
Various users want automatic demo recording.  Add new command line options:
	-auto-record-demo	start recording on level entry
	-record-demo-format	set demo name automatically

For -record-demo-format, specify a template containing any mix of strftime
insertions, variable insertions, and literal text.  As a special case, specify
"." to use the builtin template "%Y%m%d.%H%M%S-$p-$m".  Most users should use
".".  Supported variables:
	$p	name of pilot recording the demo
	$m	name of msn/mn2 file played

Suggested by jeffersoncarpenter in https://github.com/dxx-rebirth/dxx-rebirth/pull/33, but implemented by vLKp.
2015-02-28 19:36:02 +00:00
Kp 004e1371d6 Split valid/nonvalid cases of do_cockpit_window_view 2015-02-14 22:48:28 +00:00
Kp 03576a28c2 Pass PHYSFSX_* file extensions as counted array 2015-02-14 22:48:28 +00:00
Kp 99a4a0ed62 Capture range_for by-value temporaries as const
Modifying a by-value temporary does not affect the underlying container,
so modifying it is almost always a bug.  Require use of a by-reference
capture when modification is desired.

sed -i -e 's/range_for\s*(\s*\(const\s\+\)\?auto\s\+\([[:alpha:]_]\)/range_for (const auto \2/g'
2015-02-05 03:03:49 +00:00
Kp 7b0442e238 Fix crash on start of demo playback
PHYSFSX_openReadBuffered returns an RAIIPHYSFS_File, but infile was a
PHYSFS_file.  This caused the file to close instantly, leaving infile
dangling.
2015-01-29 00:56:21 +00:00
Kp 0ecea9717f Fix crash on end of demo recording 2015-01-29 00:52:35 +00:00
Kp 3ee97b1dcd Fix crash on start of demo recording
PHYSFSX_openWriteBuffered returns an RAIIPHYSFS_File, but outfile was a
PHYSFS_file.  This caused the file to close instantly, leaving outfile
dangling.
2015-01-29 00:45:18 +00:00
Kp 18a64e4281 Use RAII for PHYSFS_enumerateFiles result 2015-01-23 03:55:05 +00:00
Kp c6664a45a6 Add newmenu_do helper for array<newmenu_item, N> 2015-01-18 01:58:32 +00:00
Kp fa10e51999 Add helper nm_item_text 2015-01-18 01:58:31 +00:00
Kp f8163957ef Add helper nm_item_input 2015-01-18 01:58:31 +00:00
Kp f7815810e8 Use RAIIPHYSFS_File to manage PHYSFS_File
Fixes a few leaks on error paths.
2015-01-17 18:31:42 +00:00
Kp 68d705a85a Use bool conversion to test PHYSFS_File pointer 2015-01-17 18:31:42 +00:00
Kp fbac119095 Propagate use of objptridx_t 2014-12-23 04:20:27 +00:00
Kp b0b2704961 Allocate ND_EVENT_VIEWER_OBJECT objects from Objects 2014-12-14 21:02:40 +00:00
Kp 9ee9e176c8 Convert newdemo.cpp to use range_for 2014-12-14 05:23:01 +00:00
Kp 16113a2908 Propagate for variable in newdemo 2014-12-14 05:23:00 +00:00
Kp 227dab543c Combine shortpos scan loop 2014-12-14 05:23:00 +00:00
Kp a622aecd58 Pass vcobjptridx_t to digi_ functions 2014-12-13 17:47:06 +00:00
Kp a17cf6f808 Avoid slicing into objnum_t local 2014-11-20 03:00:41 +00:00
Kp 2c349136cc Avoid slicing into segnum_t local 2014-11-20 03:00:36 +00:00
Kp 1bb1c0ad33 Fix build break for objptr->objptridx conversions 2014-11-11 04:12:10 +00:00
Kp d408faf532 Pass nd_read_angvec arg by & 2014-11-01 14:57:25 +00:00
Kp e047d6c2b3 Pass nd_read_vector arg by & 2014-11-01 14:57:05 +00:00
Kp 1aaa08bf33 Pass nd_write_vector arg by & 2014-11-01 14:56:53 +00:00
Kp 53aa70cecb Use vsegptridx_t 2014-10-28 03:08:51 +00:00
Kp b9d1628f32 Pass nd_write_angvec arg by & 2014-10-27 03:24:08 +00:00
Kp 44bd07d031 Make polymodel->n_models unsigned 2014-10-26 22:51:27 +00:00
Kp 9a32e151ff Pass check_effect_blowup vms_vector arg by & 2014-10-26 21:36:35 +00:00
Kp ad452193ad Remove unused hostage_rescue parameter hostage_number 2014-10-17 02:05:37 +00:00
Kp 7f648c0f5f Wrap segment iteration idiom 2014-10-12 23:10:05 +00:00
Kp fb641b3250 Wrap object iteration idiom 2014-10-12 23:05:46 +00:00
Kp 99f681c8ea Pass vm_vector_2_matrix arg by & 2014-10-01 02:28:42 +00:00
Kp 4104bf4f11 Pass vm_vec_scale_add arguments by & 2014-09-28 21:43:14 +00:00
Kp 0b2636d535 Pass vm_vec_add2 arguments by & 2014-09-28 21:43:00 +00:00
Kp 74925e9b45 Pass vm_vec_scale dest by & 2014-09-28 21:11:05 +00:00
Kp a620a59bda Pass vm_vec_normalize_quick v by & 2014-09-28 21:11:04 +00:00