chore: Enabled Walls

This commit is contained in:
Syntriax 2024-01-23 12:18:41 +03:00
parent 30612fc995
commit 4ae9578123
2 changed files with 4 additions and 5 deletions

View File

@ -104,26 +104,26 @@ public class Game1 : Game
goPlayAreaTop.Transform.Position = new Vector2D(0f, 288f + 20f);
goPlayAreaTop.Transform.Scale = new Vector2D(10240f, 40f);
goPlayAreaTop.BehaviourController.AddBehaviour<DisplayableSpriteBehaviour>().Assign(spriteBox);
// goPlayAreaTop.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
goPlayAreaTop.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
engine.AddRigidBody(goPlayAreaTop.BehaviourController.AddBehaviour<RigidBody2D>());
IGameObject goPlayAreaBottom = gameManager.InstantiateGameObject<GameObject>();
goPlayAreaBottom.Transform.Position = new Vector2D(0f, -(288f + 20f));
goPlayAreaBottom.Transform.Scale = new Vector2D(10240f, 40f);
goPlayAreaBottom.BehaviourController.AddBehaviour<DisplayableSpriteBehaviour>().Assign(spriteBox);
// goPlayAreaBottom.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
goPlayAreaBottom.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
engine.AddRigidBody(goPlayAreaBottom.BehaviourController.AddBehaviour<RigidBody2D>());
IGameObject goPlayAreaRight = gameManager.InstantiateGameObject<GameObject>();
goPlayAreaRight.Transform.Position = new Vector2D(512f + 20f, 0f);
goPlayAreaRight.Transform.Scale = new Vector2D(40f, 5760f);
goPlayAreaRight.BehaviourController.AddBehaviour<DisplayableSpriteBehaviour>().Assign(spriteBox);
// goPlayAreaRight.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
goPlayAreaRight.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
engine.AddRigidBody(goPlayAreaRight.BehaviourController.AddBehaviour<RigidBody2D>());
IGameObject goPlayAreaLeft = gameManager.InstantiateGameObject<GameObject>();
goPlayAreaLeft.Transform.Position = new Vector2D(-(512f + 20f), 0f);
goPlayAreaLeft.Transform.Scale = new Vector2D(40f, 5760f);
goPlayAreaLeft.BehaviourController.AddBehaviour<DisplayableSpriteBehaviour>().Assign(spriteBox);
// goPlayAreaLeft.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
goPlayAreaLeft.BehaviourController.AddBehaviour<Collider2DAABBBehaviour>().AABBLocal = new AABB(-Vector2D.One * .5f, Vector2D.One * .5f);
engine.AddRigidBody(goPlayAreaLeft.BehaviourController.AddBehaviour<RigidBody2D>());
// IGameObject goPlayAreaCenter = gameManager.InstantiateGameObject<GameObject>();

View File

@ -1,7 +1,6 @@
using System;
using System.Collections.Generic;
using Microsoft.Xna.Framework;
using Syntriax.Engine.Core;
using Syntriax.Engine.Core.Abstract;
using Syntriax.Engine.Physics2D.Abstract;