Define a grid size to snap onto. A grid of 1x1 gives us a pixel by pixel grid. But we usually want to have 5, 10, 50, 100 or something like that.
This commit is contained in:
@ -11,11 +11,9 @@ using System.Xml.Serialization;
|
||||
using System.IO;
|
||||
using System.Resources;
|
||||
using System.Windows.Forms;
|
||||
using System.Windows;
|
||||
using System.Collections;
|
||||
|
||||
|
||||
|
||||
namespace SpriteLibrary
|
||||
{
|
||||
internal partial class SpriteEntryForm : Form
|
||||
@ -23,12 +21,14 @@ namespace SpriteLibrary
|
||||
SpriteController MyController;
|
||||
ResourceManager myResources = null;
|
||||
List<SpriteInfo> SpriteInformation = new List<SpriteInfo>();
|
||||
Size SnapGridSize = new Size(5,5);
|
||||
|
||||
internal SpriteEntryForm(ResourceManager theResourceManager, List<SpriteInfo> ListToWorkOn)
|
||||
internal SpriteEntryForm(ResourceManager theResourceManager, List<SpriteInfo> ListToWorkOn, Size GridSize)
|
||||
{
|
||||
InitializeComponent();
|
||||
if (theResourceManager == null) throw new Exception("NullException: The ResourceManager passed to the SpriteEntryForm cannot be null. Pass it Properties.Resources.ResourceManager");
|
||||
myResources = theResourceManager;
|
||||
SnapGridSize = GridSize;
|
||||
LocalSetup();
|
||||
SpriteInformation.AddRange(ListToWorkOn);
|
||||
}
|
||||
|
Reference in New Issue
Block a user