21 lines
557 B
C#
21 lines
557 B
C#
using UnityEngine;
|
|
|
|
namespace HexFiled
|
|
{
|
|
public static class HexMetrics {
|
|
|
|
public const float outerRadius = 5f;
|
|
|
|
public const float innerRadius = outerRadius * 0.866025404f;
|
|
|
|
public static Vector3[] corners = {
|
|
new Vector3(0f, 0f, outerRadius),
|
|
new Vector3(innerRadius, 0f, 0.5f * outerRadius),
|
|
new Vector3(innerRadius, 0f, -0.5f * outerRadius),
|
|
new Vector3(0f, 0f, -outerRadius),
|
|
new Vector3(-innerRadius, 0f, -0.5f * outerRadius),
|
|
new Vector3(-innerRadius, 0f, 0.5f * outerRadius),
|
|
new Vector3(0f, 0f, outerRadius)
|
|
};
|
|
}
|
|
} |