mirror of
https://github.com/Siccity/xNode.git
synced 2026-02-07 15:54:57 +08:00
Added GetSecondaryGridTexture
This commit is contained in:
parent
639680b4f2
commit
43df6ef75b
@ -53,7 +53,7 @@ namespace XNodeEditor {
|
||||
|
||||
Vector2 center = rect.size / 2f;
|
||||
Texture2D gridTex = currentGraphEditor.GetGridTexture();
|
||||
Texture2D crossTex = NodeEditorPreferences.crossTexture;
|
||||
Texture2D crossTex = currentGraphEditor.GetSecondaryGridTexture();
|
||||
|
||||
// Offset from origin in tile units
|
||||
float xOffset = -(center.x * zoom + panOffset.x) / gridTex.width;
|
||||
|
||||
@ -19,6 +19,10 @@ namespace XNodeEditor {
|
||||
return NodeEditorPreferences.gridTexture;
|
||||
}
|
||||
|
||||
public virtual Texture2D GetSecondaryGridTexture() {
|
||||
return NodeEditorPreferences.crossTexture;
|
||||
}
|
||||
|
||||
[AttributeUsage(AttributeTargets.Class)]
|
||||
public class CustomNodeGraphEditorAttribute : Attribute,
|
||||
INodeEditorAttrib {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user