Skip to content

Commit

Permalink
Small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
andybak committed Feb 18, 2024
1 parent 49a7434 commit 0ce1912
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 20 deletions.
4 changes: 2 additions & 2 deletions Assets/Scripts/StairsTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ public class StairsTest : TestBase
public float Scaling = 0;
public float Distance = 1f;
public Vector3 vector;

[ContextMenu("Go")]
public override void Go()
{
poly = Grids.Build(GridEnums.GridTypes.K_4_4_4_4, GridEnums.GridShapes.Plane, 1, 1);
poly = Grids.Build(GridEnums.GridTypes.Square, GridEnums.GridShapes.Plane, 1, 1);
for (var i = 0; i < Segments; i++)
{
poly = poly.Loft(new OpParams(0, Distance, filter: Filter.Role(Roles.Existing)));
Expand Down
26 changes: 11 additions & 15 deletions Packages/Polyhydra/com.ixxy.polyhydra/Core/Runtime/PolyMesh.cs
Original file line number Diff line number Diff line change
Expand Up @@ -381,21 +381,17 @@ public static PolyMesh GenerateConwaySeedShape(SeedShape seedShape, float param
{
var gridTypeMap = new Dictionary<string, GridEnums.GridTypes>
{
{"333333", GridEnums.GridTypes.K_3_3_3_3_3_3},
{"4444", GridEnums.GridTypes.K_4_4_4_4},
{"666", GridEnums.GridTypes.K_6_6_6},
{"33336", GridEnums.GridTypes.K_3_3_3_3_6},
{"33344", GridEnums.GridTypes.K_3_3_3_4_4},
{"33434", GridEnums.GridTypes.K_3_3_4_3_4},
{"3464", GridEnums.GridTypes.K_3_4_6_4},
{"3636", GridEnums.GridTypes.K_3_6_3_6},
{"31212", GridEnums.GridTypes.K_3_12_12},
{"4612", GridEnums.GridTypes.K_4_6_12},
{"488", GridEnums.GridTypes.K_4_8_8},
{"33412333333", GridEnums.GridTypes.K_3_3_4_12__3_3_3_3_3_3},
{"33663636", GridEnums.GridTypes.K_3_3_6_6__3_6_3_6},
{"3431231212", GridEnums.GridTypes.K_3_4_3_12__3_12_12},
{"34463636", GridEnums.GridTypes.K_3_4_4_6__3_6_3_6},
{"333333", GridEnums.GridTypes.Triangular},
{"4444", GridEnums.GridTypes.Square},
{"666", GridEnums.GridTypes.Hexagonal},
{"33336", GridEnums.GridTypes.SnubTrihexagonal},
{"33344", GridEnums.GridTypes.ElongatedTriangular},
{"33434", GridEnums.GridTypes.SnubSquare},
{"3464", GridEnums.GridTypes.Rhombitrihexagonal},
{"3636", GridEnums.GridTypes.Trihexagonal},
{"31212", GridEnums.GridTypes.TruncatedHexagonal},
{"4612", GridEnums.GridTypes.TruncatedTrihexagonal},
{"488", GridEnums.GridTypes.TruncatedSquare}
};

PolyMesh poly = null;
Expand Down
5 changes: 3 additions & 2 deletions Packages/Polyhydra/com.ixxy.polyhydra/Core/Runtime/Vertex.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
using UnityEngine;

namespace Polyhydra.Core {

public class Vertex {

#region constructors

public Vertex(float x, float y, float z)
Expand Down Expand Up @@ -56,6 +56,7 @@ public Vector3 Normal {
}
}

// TODO - is this the same as HalfEdges?
public List<Vertex> Neighbours
{
get {
Expand Down
3 changes: 2 additions & 1 deletion ProjectSettings/PackageManagerSettings.asset
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ MonoBehaviour:
- com.nomnom.new-package-helper
- com.openupm
- com.syomus.proceduraltoolkit
- jillejr.newtonsoft.json-for-unity
m_IsDefault: 0
m_Capabilities: 0
m_ConfigSource: 4
Expand All @@ -42,6 +43,6 @@ MonoBehaviour:
m_RegistryInfoDraft:
m_Modified: 0
m_ErrorMessage:
m_UserModificationsInstanceId: -824
m_UserModificationsInstanceId: -826
m_OriginalInstanceId: -828
m_LoadAssets: 50

0 comments on commit 0ce1912

Please sign in to comment.