Ejemplo n.º 1
0
    // Update is called once per frame
    void Update()
    {
        timeTillNextSpawn -= Time.deltaTime;

        if (timeTillNextSpawn < 0)
        {
            timeTillNextSpawn = timeBetweenSpawns;

            ExplosiveFactory.CreateExplosive(ExplosiveID, transform.position, 0);
        }
    }
Ejemplo n.º 2
0
        private static void AddExplosion(Entity entity, Vector3 hitPoint, uint ownerID)
        {
            Explosive explosive = EntityManager.GetComponentData <Explosive>(entity);

            ExplosiveFactory.CreateExplosive(explosive.ID, hitPoint, ownerID);
        }