Prepicked plants editor

This commit is contained in:
Rendo 2025-07-29 04:08:05 +05:00
commit 56f75a5d06
43 changed files with 532 additions and 50 deletions

View file

@ -21,8 +21,7 @@ public partial class GameRegistry : Node
if (ResourceLoader.Exists(PLANT_RESOURCE_PATH + file))
{
var plant = ResourceLoader.Load<PlantResource>(PLANT_RESOURCE_PATH + file);
plant.internal_id = file.ToLower().Split('.')[0];
EntityDictionary.Add(file.ToLower().Split('.')[0], plant);
EntityDictionary.Add(plant.GetInternalID(), plant);
}
}
//Zombie init
@ -33,8 +32,7 @@ public partial class GameRegistry : Node
if (ResourceLoader.Exists(ZOMBIE_RESOURCE_PATH + file))
{
var zombie = ResourceLoader.Load<ZombieResource>(ZOMBIE_RESOURCE_PATH + file);
zombie.internal_id = file.ToLower().Split('.')[0];
EntityDictionary.Add(file.ToLower().Split('.')[0], zombie);
EntityDictionary.Add(zombie.GetInternalID(), zombie);
}
}
}