Started the great comment update.
This commit is contained in:
parent
9834bbcf28
commit
fabef6ba82
|
@ -90,6 +90,7 @@ namespace CustomNPCFramework
|
||||||
private void GameEvents_UpdateTick(object sender, EventArgs e)
|
private void GameEvents_UpdateTick(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
if (Game1.player.currentLocation == null) return;
|
if (Game1.player.currentLocation == null) return;
|
||||||
|
if (Game1.activeClickableMenu != null) return;
|
||||||
foreach (var v in Game1.player.currentLocation.characters)
|
foreach (var v in Game1.player.currentLocation.characters)
|
||||||
{
|
{
|
||||||
v.speed = 1;
|
v.speed = 1;
|
||||||
|
|
|
@ -6,11 +6,26 @@ using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace CustomNPCFramework.Framework.Enums
|
namespace CustomNPCFramework.Framework.Enums
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A enum of different types of animations supported by the framework.
|
||||||
|
/// </summary>
|
||||||
public enum AnimationType
|
public enum AnimationType
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A key to be used whenever an npc uses a standing animation.
|
||||||
|
/// </summary>
|
||||||
standing,
|
standing,
|
||||||
|
/// <summary>
|
||||||
|
/// A key to be used wheneven an npc uses a walking/moving animation.
|
||||||
|
/// </summary>
|
||||||
walking,
|
walking,
|
||||||
|
/// <summary>
|
||||||
|
/// A key to be used whenever an npc uses a swimming animation.
|
||||||
|
/// </summary>
|
||||||
swimming,
|
swimming,
|
||||||
|
/// <summary>
|
||||||
|
/// A key to be used whenever an npc uses a sitting animation.
|
||||||
|
/// </summary>
|
||||||
sitting
|
sitting
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,11 +6,31 @@ using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace CustomNPCFramework.Framework.Enums
|
namespace CustomNPCFramework.Framework.Enums
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// An enum to be used to signify directions.
|
||||||
|
/// The enum order corresponds to the same order Stardew Valley uses for directions where
|
||||||
|
/// Up=0
|
||||||
|
/// Right=1
|
||||||
|
/// Down=2
|
||||||
|
/// Left=3
|
||||||
|
/// </summary>
|
||||||
public enum Direction
|
public enum Direction
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify something to face/move up.
|
||||||
|
/// </summary>
|
||||||
up,
|
up,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify something to face/move right.
|
||||||
|
/// </summary>
|
||||||
right,
|
right,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify something to face/move down.
|
||||||
|
/// </summary>
|
||||||
down,
|
down,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify something to face/move left.
|
||||||
|
/// </summary>
|
||||||
left
|
left
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,12 +7,22 @@ using System.Threading.Tasks;
|
||||||
namespace CustomNPCFramework.Framework.Enums
|
namespace CustomNPCFramework.Framework.Enums
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
/// Gender enum to signify the different genders for npcs.
|
||||||
/// Do what you want with this. For code simplicity anything that is non-binary is specified under other.
|
/// Do what you want with this. For code simplicity anything that is non-binary is specified under other.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public enum Genders
|
public enum Genders
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Used for npcs to signify that they are the male gender.
|
||||||
|
/// </summary>
|
||||||
male,
|
male,
|
||||||
|
/// <summary>
|
||||||
|
/// Used for npcs to signify that they are the female gender.
|
||||||
|
/// </summary>
|
||||||
female,
|
female,
|
||||||
|
/// <summary>
|
||||||
|
/// Used for npcs to signify that they are a non gender binary gender.
|
||||||
|
/// </summary>
|
||||||
other
|
other
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,15 +6,50 @@ using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace CustomNPCFramework.Framework.Enums
|
namespace CustomNPCFramework.Framework.Enums
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// An enum used to signify the different asset types that can be used for npcs.
|
||||||
|
/// </summary>
|
||||||
public enum PartType
|
public enum PartType
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the body part category. Without this the npc is basically a ghost.
|
||||||
|
/// </summary>
|
||||||
body,
|
body,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the eyes part category. The window to the soul.
|
||||||
|
/// </summary>
|
||||||
eyes,
|
eyes,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the hair part category. Volume looks good in 2D.
|
||||||
|
/// </summary>
|
||||||
hair,
|
hair,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the shirt part category.No shirt = no service.
|
||||||
|
/// </summary>
|
||||||
shirt,
|
shirt,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the pants/bottoms part category. Also known as bottoms, skirts, shorts, etc.
|
||||||
|
/// </summary>
|
||||||
pants,
|
pants,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the shoes part category. Lace up those kicks.
|
||||||
|
/// </summary>
|
||||||
shoes,
|
shoes,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the accessort part category. Got to wear that bling.
|
||||||
|
/// </summary>
|
||||||
accessory,
|
accessory,
|
||||||
other
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the other part category. Who knows what this really is...
|
||||||
|
/// </summary>
|
||||||
|
other,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the swimsuit part category. Got to be decent when taking a dip.
|
||||||
|
/// </summary>
|
||||||
|
swimsuit,
|
||||||
|
/// <summary>
|
||||||
|
/// Used to signify that the asset is of the amrs part category. Arms need to be rendered above a shirt on npcs otherwise they get covered.
|
||||||
|
/// </summary>
|
||||||
|
arms
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,13 +4,33 @@ using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
|
||||||
namespace CustomNPCFramework.Framework.Enums
|
namespace CustomNPCFramework.Framework.Enums
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// An enum signifying the different seasons that are supported when chosing npc graphics.
|
||||||
|
/// </summary>
|
||||||
public enum Seasons
|
public enum Seasons
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The spring season. This ensures that a corresponding graphic with this enum in it's seasons list can be chosen in the spring time.
|
||||||
|
/// Also used for functionality to check seasons.
|
||||||
|
/// </summary>
|
||||||
spring,
|
spring,
|
||||||
|
/// <summary>
|
||||||
|
/// The summer season. This ensures that a corresponding graphic with this enum in it's seasons list can be chosen in the summer time.
|
||||||
|
/// Also used for functionality to check seasons.
|
||||||
|
/// </summary>
|
||||||
summer,
|
summer,
|
||||||
|
/// <summary>
|
||||||
|
/// The fall season. This ensures that a corresponding graphic with this enum in it's seasons list can be chosen in the fall time.
|
||||||
|
/// Also used for functionality to check seasons.
|
||||||
|
/// </summary>
|
||||||
fall,
|
fall,
|
||||||
|
/// <summary>
|
||||||
|
/// The winter season. This ensures that a corresponding graphic with this enum in it's seasons list can be chosen in the winter time.
|
||||||
|
/// Also used for functionality to check seasons.
|
||||||
|
/// </summary>
|
||||||
winter
|
winter
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,18 +8,48 @@ using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace CustomNPCFramework.Framework.Graphics.TextureGroups
|
namespace CustomNPCFramework.Framework.Graphics.TextureGroups
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A group of a textures used to hold all of the textures associated with a single asset such as a hair style or a shirt.
|
||||||
|
/// </summary>
|
||||||
public class TextureGroup
|
public class TextureGroup
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The directional (Left, Right, Up, Down) textures to be used when the NPC is standing.
|
||||||
|
/// </summary>
|
||||||
public DirectionalTexture standingTexture;
|
public DirectionalTexture standingTexture;
|
||||||
|
/// <summary>
|
||||||
|
/// The directional (Left, Right, Up, Down) textures to be used when the NPC is sitting.
|
||||||
|
/// </summary>
|
||||||
public DirectionalTexture sittingTexture;
|
public DirectionalTexture sittingTexture;
|
||||||
|
/// <summary>
|
||||||
|
/// The directional (Left, Right, Up, Down) textures to be used when the NPC is swimming.
|
||||||
|
/// </summary>
|
||||||
public DirectionalTexture swimmingTexture;
|
public DirectionalTexture swimmingTexture;
|
||||||
|
/// <summary>
|
||||||
|
/// The directional (Left, Right, Up, Down) textures to be used when the NPC is moving.
|
||||||
|
/// </summary>
|
||||||
public DirectionalTexture movingTexture;
|
public DirectionalTexture movingTexture;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The current directional texture to be used by the npc. Can be things such as the standing, swimming, moving, or sitting texture.
|
||||||
|
/// </summary>
|
||||||
public DirectionalTexture currentTexture;
|
public DirectionalTexture currentTexture;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Asset info loaded in from the corresponding .json file.
|
||||||
|
/// </summary>
|
||||||
private AssetInfo info;
|
private AssetInfo info;
|
||||||
|
/// <summary>
|
||||||
|
/// The path to the .json file.
|
||||||
|
/// </summary>
|
||||||
private string path;
|
private string path;
|
||||||
|
/// <summary>
|
||||||
|
/// The current direction of the texture group. See Direction.cs
|
||||||
|
/// </summary>
|
||||||
private Direction dir;
|
private Direction dir;
|
||||||
|
/// <summary>
|
||||||
|
/// The type of asset this is. Body, hair, eyes, shirt,etc...
|
||||||
|
/// </summary>
|
||||||
private AnimationType type;
|
private AnimationType type;
|
||||||
|
|
||||||
public TextureGroup(AssetInfo info, string path,Direction direction ,AnimationType animationType=AnimationType.standing)
|
public TextureGroup(AssetInfo info, string path,Direction direction ,AnimationType animationType=AnimationType.standing)
|
||||||
|
|
Loading…
Reference in New Issue