mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 12:31:54 +00:00
Merge branch 'start-netid-at-1' into 'next'
Avoid CV_FindNetVar returning a normal cvar (closes #251) Closes #251 See merge request STJr/SRB2!1137
This commit is contained in:
commit
3e511b131f
1 changed files with 3 additions and 3 deletions
|
|
@ -1262,12 +1262,12 @@ void CV_RegisterVar(consvar_t *variable)
|
||||||
// check net variables
|
// check net variables
|
||||||
if (variable->flags & CV_NETVAR)
|
if (variable->flags & CV_NETVAR)
|
||||||
{
|
{
|
||||||
variable->netid = consvar_number_of_netids++;
|
|
||||||
|
|
||||||
/* in case of overflow... */
|
/* in case of overflow... */
|
||||||
if (variable->netid > consvar_number_of_netids)
|
if (consvar_number_of_netids + 1 < consvar_number_of_netids)
|
||||||
I_Error("Way too many netvars");
|
I_Error("Way too many netvars");
|
||||||
|
|
||||||
|
variable->netid = ++consvar_number_of_netids;
|
||||||
|
|
||||||
#ifdef OLD22DEMOCOMPAT
|
#ifdef OLD22DEMOCOMPAT
|
||||||
CV_RegisterOldDemoVar(variable);
|
CV_RegisterOldDemoVar(variable);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue