fixed port conflicts
This commit is contained in:
@ -62,7 +62,7 @@ namespace Convai.Scripts.Runtime.Multiplayer
|
||||
if (cfg != null)
|
||||
{
|
||||
targetIP = cfg.ipAddress;
|
||||
targetPort = cfg.port;
|
||||
targetPort = cfg.multiplayerSpeechPort;
|
||||
}
|
||||
}
|
||||
InitializeNetwork();
|
||||
@ -93,8 +93,13 @@ namespace Convai.Scripts.Runtime.Multiplayer
|
||||
|
||||
private void InitializeConvai()
|
||||
{
|
||||
// Get target NPC
|
||||
if (useActiveNPC)
|
||||
// Prefer local ConvaiNPC on the same GameObject, then fall back to active NPC
|
||||
var localNPC = GetComponent<ConvaiNPC>();
|
||||
if (localNPC != null)
|
||||
{
|
||||
sourceNPC = localNPC;
|
||||
}
|
||||
else if (useActiveNPC)
|
||||
{
|
||||
sourceNPC = ConvaiNPCManager.Instance?.GetActiveConvaiNPC();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user