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
Kp
f073e9e377
Fold nm_messagebox call in net_udp_do_join_game
2016-05-28 17:31:27 +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
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
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
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
20e72128de
Add configure test and fallback code to support ancient Windows
...
Windows 2000 has no support for getaddrinfo. Five years ago (Apr 5
2011), the addition of tracker support
(7f18afd5d7
) brought a requirement for
getaddrinfo. Recently, someone with a working Windows 2000 system
reported that Rebirth no longer starts on Windows 2000. Although such
systems should not be connected to the Internet, they may still need
name resolution on a LAN. Add a configure test to probe for getaddrinfo
support and fall back to gethostbyname if needed.
Compiling a binary that works on Windows 2000 requires one of:
* using an ancient SDK that does not declare getaddrinfo
* defining _WIN32_WINNT to exclude Windows XP support
* overriding the SConf test to force failure
Fixes: 7f18afd5d7
("Client-side implementation for Tracker support by Matt 1360 Vandermeulen including improvements in udp_dns_filladdr and IPv4/IPv6 compability; Very little adjustments by me, too including IPv6 support for Windows (untested); Actual tracker code will follow later as seperate branch when it's done")
2016-03-18 02:05:16 +00:00
zico
57c33695e6
Do not read pdata packets while the level isn't loaded and try not to send packets to players in these states.
2016-03-05 12:05:43 +01: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
zico
2e6aa0f081
Took out obj_unlink() call in net_udp_read_object_packet(). As of 7064fcccba
obj->segnum is undefined and obj_unlink() would be called for undefined objects, causing some new objects to not appear for rejoining players. Since init_objects() is called beforehand and host should not be able to send the same object twice, this whole call should be unnecessary to begin with.
2016-02-23 14:25:17 +01: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
b57f08c798
Use partial_const_range
2016-02-12 04:02:28 +00:00
Kp
74dfa29d31
Convert most Trigger references to valptridx
2016-02-06 22:12:54 +00:00
Kp
0d1dd636ca
Move extraAccessory into if(D2)
...
It is only used in D2, so do not use the space when compiling D1.
2016-02-02 03:10:53 +00:00
Kp
124a2ee09c
Move net_udp.cpp specific defines out of header
2016-01-26 03:45:06 +00:00
Kp
7386094bc3
Rename menu macros to reduce token pasting
2016-01-09 16:38:17 +00:00
Kp
2b34547b05
Remove redundant DXX_UDP_MENU_OPTIONS(ENUM)
2016-01-09 16:38:17 +00:00
Kp
079c4d8b5c
Move netgame setup strings to param_opt
2016-01-09 16:38:15 +00:00
Kp
bc392aaaf3
Move net_udp start_poll data onto stack
2016-01-09 16:38:15 +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
4f14be6056
Move MplUdpHostAddr to CArg
2015-12-24 04:01:27 +00:00
Kp
e8c34be843
Use v*ptr* factories with highest_valid
2015-12-22 04:18:51 +00:00
zico
2e6dae1d8b
Abbreviated some text strings to make menus fit better into a 4x3 game window.
2015-12-14 15:32:42 +01:00
Kp
708dc0a7e1
Use vobjptr/vcobjptr for more Objects[] access
2015-12-03 03:26:49 +00:00
Kp
b683b4cc68
Scope weapon type
2015-12-03 03:26:49 +00:00
Kp
f72e739732
Defer initializing UDP bind address
2015-11-26 02:56:55 +00:00
Kp
82d0c2ed96
Make some implicit uses of ptridx construction explicit
2015-11-19 03:23:34 +00:00
Kp
6b353cb9ac
Move player powerup_flags to object.ctype.player_info
2015-11-07 21:55:59 +00:00
Kp
731e287329
Clean up trailing whitespace on rank strings
2015-10-30 02:52:55 +00:00
Kp
070444157e
Use type safe player flags
2015-10-30 02:52:55 +00:00
Kp
7ac2840bfe
Rename Netgame.player_flags to .net_player_flags
...
The simple name conflicts with an upcoming change.
2015-10-30 02:52:54 +00:00
Kp
ea3c4a8986
Switch const multi text to array<>
2015-10-29 03:01:43 +00:00
Kp
78de0ac119
Add fwd-event.h with forward declarations of event.h
2015-10-09 02:46:10 +00:00
Kp
aa1a1c5a6a
Fix regressions from changes to advanced host menu
...
Non-static globals were initialized at wrong scope, leading to netgame
duplicate options being forgotten across program restart.
Netgame.DuplicatePowerups is not initialized until well after global
initialization runs.
Literal strings were copied into a local buffer. Replace with a pointer
to the appropriate literal string.
Fixes: aa9a5df0d4
("Rearrange Advanced Hosting Menu")
2015-10-03 17:17:49 +00:00
Christian
ab85c6f0e9
Merge pull request #144 from Mako88/new-menu
...
Rearrange Advanced Hosting Menu (by Mako88/A Future Pilot)
2015-09-29 13:41:12 +02:00
Kp
d9cef82f81
Allow nullptr for gr_get_string_size
2015-09-29 02:41:22 +00:00
Kp
71ffbdf719
Replace fill(0) with ={}
2015-09-29 02:41:22 +00:00
John Ackerman
0e73b2a209
Revert "Change friendly fire wording"
...
This reverts commit 8128d68e3d
.
2015-09-27 12:40:14 -05:00
John Ackerman
8128d68e3d
Change friendly fire wording
2015-09-25 16:52:41 -05:00
John Ackerman
aa9a5df0d4
Rearrange Advanced Hosting Menu
2015-09-25 15:31:42 -05:00
Kp
c0e7f70638
Update reactor life text as slider moves
...
Reported-by: Mako88 <https://github.com/dxx-rebirth/dxx-rebirth/issues/125 >
2015-09-22 02:28:38 +00:00