mirror of
https://github.com/boudji-ludwig-pett/cnam-geometry-dash.git
synced 2025-06-10 22:20:40 +02:00
feat: init AI (#60)
This commit is contained in:
@ -38,6 +38,11 @@ public class LevelLoader : MonoBehaviour
|
||||
GameObject prefab = GetPrefab(element.type);
|
||||
GameObject instance = Instantiate(prefab, new Vector3(element.x, element.y, 0), Quaternion.identity);
|
||||
|
||||
// if (prefab.CompareTag("Kill"))
|
||||
// {
|
||||
Instantiate(Resources.Load<GameObject>("AICollider"), new Vector3(element.x - 1, element.y, 0), Quaternion.identity);
|
||||
// }
|
||||
|
||||
Vector3 originalScale = instance.transform.localScale;
|
||||
float newScaleX = element.scaleX > 0 ? element.scaleX : originalScale.x;
|
||||
float newScaleY = element.scaleY > 0 ? element.scaleY : originalScale.y;
|
||||
|
Reference in New Issue
Block a user