static int GetLayerCost(IntPtr L) { LuaScriptMgr.CheckArgsCount(L, 2); NavMeshAgent obj = LuaScriptMgr.GetNetObject <NavMeshAgent>(L, 1); int arg0 = (int)LuaScriptMgr.GetNumber(L, 2); float o = obj.GetLayerCost(arg0); LuaScriptMgr.Push(L, o); return(1); }
static int GetLayerCost(IntPtr L) { LuaScriptMgr.CheckArgsCount(L, 2); NavMeshAgent obj = (NavMeshAgent)LuaScriptMgr.GetUnityObjectSelf(L, 1, "NavMeshAgent"); int arg0 = (int)LuaScriptMgr.GetNumber(L, 2); float o = obj.GetLayerCost(arg0); LuaScriptMgr.Push(L, o); return(1); }
void DoGetLayerCost() { if (_agent == null) { return; } int layerId = layer.Value; if (ORlayerName.Value != "") { layerId = NavMesh.GetNavMeshLayerFromName(ORlayerName.Value); } storeResult.Value = _agent.GetLayerCost(layerId); }