Hey everyone. I'm trying to spawn a Scientist and everything is hunky dory until I kill it... then server starts spamming Effect.Init - invalid entity... until I disconnect... whats wrong? Thanks. :)
using System;
using System.Collections.Generic;
using UnityEngine;
namespace Oxide.Plugins
{
[Info("Test", "Me", 0.1)]
[Description("Test")]
class Test : RustPlugin
{
void TestR(Vector3 testPos)
{
BasePlayer testbotone = GameManager.server.CreateEntity("assets/prefabs/npc/scientist/scientist.prefab", testPos) as BasePlayer;
testbotone.Spawn();
}
[ChatCommand("te")]
void chatCommandTe(BasePlayer player, string command, string[] args)
{
var position = player.transform.position;
TestR(position);
}
}
}