Adds config option for traffic in COOPAPI

And removes the welcome message in NON INTERACTIVE mode
(Press F9 is not possible in that compilation mode)
This commit is contained in:
Makinolo
2021-12-07 22:14:15 -07:00
parent 857b1b7622
commit 9fc92f5293
2 changed files with 4 additions and 2 deletions

View File

@ -228,11 +228,12 @@ namespace CoopClient
/// <summary> /// <summary>
/// ? /// ?
/// </summary> /// </summary>
public static void Configure(string playerName, bool shareNpcsWithPlayers, int streamedNpcs, bool debug = false) public static void Configure(string playerName, bool shareNpcsWithPlayers, int streamedNpcs, bool disableTrafficSharing, bool debug = false)
{ {
Main.MainSettings.Username = playerName; Main.MainSettings.Username = playerName;
Main.ShareNpcsWithPlayers = shareNpcsWithPlayers; Main.ShareNpcsWithPlayers = shareNpcsWithPlayers;
Main.MainSettings.StreamedNpc = streamedNpcs; Main.MainSettings.StreamedNpc = streamedNpcs;
Main.DisableTraffic = disableTrafficSharing;
#if DEBUG #if DEBUG
Main.UseDebug = debug; Main.UseDebug = debug;
#endif #endif

View File

@ -80,8 +80,9 @@ namespace CoopClient
{ {
RelationshipGroup = World.AddRelationshipGroup("SYNCPED"); RelationshipGroup = World.AddRelationshipGroup("SYNCPED");
Game.Player.Character.RelationshipGroup = RelationshipGroup; Game.Player.Character.RelationshipGroup = RelationshipGroup;
#if !NON_INTERACTIVE
GTA.UI.Notification.Show(GTA.UI.NotificationIcon.AllPlayersConf, "GTACOOP:R", "Welcome!", "Press ~g~F9~s~ to open the menu."); GTA.UI.Notification.Show(GTA.UI.NotificationIcon.AllPlayersConf, "GTACOOP:R", "Welcome!", "Press ~g~F9~s~ to open the menu.");
#endif
} }
#if !NON_INTERACTIVE #if !NON_INTERACTIVE