Esempio n. 1
0
        protected override void OnStart()
        {
            base.OnStart();

            UI.AddInfo("Press Space to launch a firework.");
            UI.AddSlider("Angle", 0f, 90f, 0f).Slider.ValueChanged += OnAngleValueChanged;

            _fireworkLauncher = GetEntity <FireworkLauncher>();
        }
        protected override void OnStart()
        {
            UI.AddInfo("Left-click anywhere to fire a projectile.");

            _projectileSpawner = EntityFramework.GetEntity <ProjectileSpawner>();
            if (_projectileSpawner == null)
            {
                Log.Error <ProjectileLevel>("Failed to find a ProjectileSpawner in the level");
            }
        }
Esempio n. 3
0
        protected override void OnStart()
        {
            _baseMoveSpeed          = 7.5f;
            _moveSpeedShiftModifier = 0.25f;

            UI.AddInfo("Press A or D to move the beam left or right. Press Space to spawn a ball.").Text.Color = Color.White;
            UI.AddSlider("Distance", 0.1f, 20f, 20f).Slider.ValueChanged += Distance_Slider_ValueChanged;

            _raycaster = EntityFramework.GetEntity <Raycaster>();
            if (_raycaster == null)
            {
                Log.Error <RaycastLevel>("Failed to find a Raycaster entity in the current level.");
            }
        }
Esempio n. 4
0
 protected override void OnStart()
 {
     base.OnStart();
     UI.AddInfo("Left-click to destroy an entity.");
 }