This commit is contained in:
SergoDobro 2024-08-20 20:10:46 +03:00
parent 0ae47df396
commit 1be2ca09c5
7 changed files with 8 additions and 4 deletions

View file

@ -107,7 +107,7 @@ namespace ZoFo.GameCore
float shakeEffect = 0;
public void AddShaking(float power)
{
shakeEffect += power;
shakeEffect += power*3;
}
public void UpdateShaking()
{

View file

@ -31,6 +31,7 @@ public class DebugHUD
public void Draw(SpriteBatch spriteBatch)
{
return;//TODO delete
var keysString = Join("\n", _text.Select(el => el.Key + ": " + el.Value).ToList());
spriteBatch.Begin();
spriteBatch.DrawString(

View file

@ -133,7 +133,7 @@ namespace ZoFo.GameCore.GameManagers
protected override void Draw(GameTime gameTime)
{
GraphicsDevice.Clear(Color.CornflowerBlue);
GraphicsDevice.Clear(Color.Black);
// Pointwrap

View file

@ -13,6 +13,8 @@ namespace ZoFo.GameCore.GameManagers.ItemManager
//методы
public ItemInfo GetItemInfo(string tag)
{
if (tag == "peeble")
return tagItemPairs["pebble"];
return tagItemPairs[tag];
}
public void LoadItemTextures()

View file

@ -22,7 +22,7 @@ namespace ZoFo.GameCore.GameObjects
public Zombie(Vector2 position) : base(position)
{
health = 5;
speed = 0.5f;
speed = 2.0f;
graphicsComponent.ObjectDrawRectangle = new Rectangle(0, 0, 30, 30);
collisionComponent.stopRectangle = new Rectangle(10, 20, 10, 10);
isAttacking = false;

View file

@ -50,7 +50,7 @@ public class Player : LivingEntity
lootData.loots = new Dictionary<string, int>();
graphicsComponent.ObjectDrawRectangle = new Rectangle(0, 0, 30, 30);
collisionComponent.stopRectangle = new Rectangle(10, 15, 10, 15);
speed = 5;
speed = 7;
StartAnimation("player_look_down");
}

View file

@ -103,6 +103,7 @@ public abstract class GameObject
}
public void DrawDebugRectangle(SpriteBatch spriteBatch, Rectangle _rectangle, Nullable<Color> color = null)
{
return;
if (color is null) color = new Color(1, 0, 0, 0.1f);
if (color.Value.A == 255) color = new Color(color.Value, 0.25f);
spriteBatch.Draw(debugTexture,