Hi.
I think vector3int is not supported yet to display the variable (PM 1.8.9) , but it can be used private.
It might be already included in the playmaker beta, i will ask Alex.
for now you have 2 options.
You can get each vector separately (FsmInt)
Or you can use a fsmvector3
on the code below both are implemented :
// (c) Copyright HutongGames, LLC 2010-2018. All rights reserved.
//--- __ECO__ __PLAYMAKER__ __ACTION__ ---//
using UnityEngine;
using UnityEngine.Tilemaps;
namespace HutongGames.PlayMaker.Actions
{
[ActionCategory("Tilemaps")]
[Tooltip("Sets a tile at the given XYZ coordinates of a cell in the tile map.")]
public class SetTile : FsmStateAction
{
[RequiredField]
[CheckForComponent(typeof(Tilemap))]
[Tooltip("Tilemap to place the tile on.")]
public Tilemap tilemap;
public FsmInt vector3X;
public FsmInt vector3Y;
public FsmInt vector3Z;
[Tooltip("If a vector 3 is set, the above variables will be ignored")]
public FsmVector3 vector3Variable;
[RequiredField]
[Tooltip("The cell position to place the tile.")]
private Vector3Int vector3IntValue;
[RequiredField]
[Tooltip("The tile to set.")]
[ObjectType(typeof(UnityEngine.Tilemaps.TileBase))]
public FsmObject ruleTile;
public override void Reset()
{
vector3X = new FsmInt { UseVariable = true };
vector3Y = new FsmInt { UseVariable = true };
vector3Z = new FsmInt { UseVariable = true };
vector3Variable = new FsmVector3 { UseVariable = true };
tilemap = null;
ruleTile = null;
}
public override void OnEnter()
{
if (vector3Variable == null)
{
vector3IntValue = new Vector3Int(vector3X.Value, vector3Y.Value, vector3Z.Value);
}
else
{
vector3IntValue = new Vector3Int(Mathf.RoundToInt(vector3X.Value), Mathf.RoundToInt(vector3Y.Value), Mathf.RoundToInt(vector3Z.Value));
}
tilemap.SetTile (vector3IntValue, ruleTile.Value as TileBase);
}
public override void OnUpdate()
{
}
}
}