particles/Main.cs

18 lines
514 B
C#
Raw Normal View History

2021-12-26 14:58:58 -05:00
using Godot;
2022-01-17 23:52:42 -05:00
using System;
2021-12-26 14:58:58 -05:00
2022-01-17 23:52:42 -05:00
public class Main : Node
2021-12-26 14:58:58 -05:00
{
2021-12-27 14:58:33 -05:00
2022-01-17 23:52:42 -05:00
public void StartSimulation(int nParticles)
2021-12-27 16:10:07 -05:00
{
2022-01-17 23:52:42 -05:00
var particleSimulationPackedScene = GD.Load<PackedScene>("res://ParticleSimulationScene.tscn");
var particleSimulationScene = particleSimulationPackedScene.Instance<ParticleSimulationScene>();
AddChild(particleSimulationScene);
particleSimulationScene.Initialize(nParticles);
GetNode<Control>("MainMenu").Hide();
//OS.WindowResizable = false;
2021-12-26 21:16:28 -05:00
}
2022-01-17 23:52:42 -05:00
}