mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 19:10:32 +00:00
only ninja NPCs
This commit is contained in:
parent
0d6868b693
commit
0d461a8836
@ -38,12 +38,12 @@ void Update()
|
|||||||
[Command]
|
[Command]
|
||||||
void CmdSpawnNPC()
|
void CmdSpawnNPC()
|
||||||
{
|
{
|
||||||
GameObject npc = Instantiate(TestNTNetworkManager.singleton.npcPrefab);
|
//GameObject npc = Instantiate(TestNTNetworkManager.singleton.npcPrefab);
|
||||||
npc.GetComponent<PlayerName>().playerName = "NPC";
|
//npc.GetComponent<PlayerName>().playerName = "NPC";
|
||||||
npc.GetComponent<CharacterController>().enabled = true;
|
//npc.GetComponent<CharacterController>().enabled = true;
|
||||||
npc.GetComponent<PlayerMove>().enabled = true;
|
//npc.GetComponent<PlayerMove>().enabled = true;
|
||||||
NetworkServer.Spawn(npc);
|
//NetworkServer.Spawn(npc);
|
||||||
NpcList.Add(npc);
|
//NpcList.Add(npc);
|
||||||
|
|
||||||
GameObject npcNinja = Instantiate(TestNTNetworkManager.singleton.npcNinjaPrefab);
|
GameObject npcNinja = Instantiate(TestNTNetworkManager.singleton.npcNinjaPrefab);
|
||||||
npcNinja.GetComponent<PlayerName>().playerName = "NPC-Ninja";
|
npcNinja.GetComponent<PlayerName>().playerName = "NPC-Ninja";
|
||||||
|
Loading…
Reference in New Issue
Block a user