2022-12-28 16:22:53 +01:00
|
|
|
using Godot;
|
|
|
|
|
2023-11-18 22:32:57 +01:00
|
|
|
public class WorldInfoComponent : Component {
|
2023-11-10 11:11:08 +01:00
|
|
|
[Export] public NodePath WorldPath;
|
|
|
|
public World World;
|
2022-12-28 16:22:53 +01:00
|
|
|
|
|
|
|
// Called when the node enters the scene tree for the first time.
|
2023-11-18 22:32:57 +01:00
|
|
|
public override void _Ready() {
|
2023-11-10 11:11:08 +01:00
|
|
|
World = GetNode<World>(WorldPath);
|
2022-12-28 16:22:53 +01:00
|
|
|
}
|
|
|
|
|
2023-11-18 22:32:57 +01:00
|
|
|
public void SetWorld(World world) {
|
2023-11-10 11:11:08 +01:00
|
|
|
World = world;
|
2022-12-28 16:22:53 +01:00
|
|
|
}
|
|
|
|
}
|