Thread: rations and waterskins
-
June 27th, 2019, 02:22 #21
Unfortunately I'm just a beginner in the extensions thing ... Maybe someone is interested in doing it.
The healer's kit is usually added to the actions tab as a power with number of uses or a weapon with a set amount of ammo. Otherwise I suspect you are going to need to write a custom extension. Though maybe someone else has an ingenious idea?
-
June 27th, 2019, 04:26 #22
The "ammo" is accounted for on each character. So isn't that the same as each carrying their own supplies? It might still work with parcels, you would have to make a custom weapon type of ammo though, just like an arrow or bolt.
But, you can also insist on using it like currency, but then you are limited to 6 currency types, which probably mean you have to stop using copper and maybe silver.
Problems? See; How to Report Issues, Bugs & Problems
On Licensing & Distributing Community Content
Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
Note, I am not a SmiteWorks employee or representative, I'm just a user like you.
-
June 27th, 2019, 04:30 #23which probably mean you have to stop using copper and maybe silver
Ammo idea is good. I think using a customizable power like the Lay of Hands is an elegant solution, but there is no warning that the uses have ended as the case of ammunition.
-
August 7th, 2019, 15:08 #24
Just wanted to say that I really liked a lot of the feedback and ideas. Some really awesome efforts by many who also see where I was coming from.
Thank you all!
One day a savvy programmer like the mysterious DuluxOz and the magnificent Celestian, will solve this for us, and we'll be like ... dude(tte) you are a hero!
-
April 28th, 2020, 12:31 #25
- Join Date
- May 2018
- Posts
- 199
Maybe a message can be generated in chat as a reminder for players or dm that rations and waterskin need to be deducted. Just add it onto the text stating party is taking a long rest. It just slips my mind to tell everyone to deduct rations.
-
May 13th, 2020, 18:05 #26
i have been working on code that uses the calendar to track things like when to regain health, when to lose stress points, when to gain or lose radiation, when to roll for a condition or lose health because of it, or when a critical injury has reached a count of passing time before the character has to roll, or to roll for consumable items when needed.
this is all for the Alien RPG ruleset of course, but i can break down some of the code i used here.
https://www.fantasygrounds.com/forum...en-RPG-ruleset
in the manager_char.lua i have most of my code in place.
Code:this one sets when you start the time for whatever you're needing. if you are using a button to "start tracking" hunger, for instance, you would put this in the script for that function setStartTime(rActor, sFirst) --Debug.console("setStartTime called; " .. sFirst ..""); local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); nStartTime = getCurrentDateinMinutes(rActor); --Debug.console("setStartTime; nStartTime =", nStartTime); DB.setValue(nodeActor, "" .. sFirst .. ".starttime", "number", nStartTime); --Debug.console("setStartTime; DB.setValue(nodeActor, " .. sFirst .. ".starttime, number, " .. nStartTime .. ") = ", DB.setValue(nodeActor, "" .. sFirst .. ".starttime", "number", nStartTime)); end this one gets the current date and makes turns it all into minutes function getCurrentDateinMinutes(rActor) --Debug.console("getCurrentDateinMinutes; nRounds =", nRounds); local nMinutes = DB.getValue("calendar.current.minute"); --Debug.console("getCurrentDateinMinutes; nMinutes =", nMinutes); local nHours = DB.getValue("calendar.current.hour"); --Debug.console("getCurrentDateinMinutes; nHours =", nHours); local nDays = DB.getValue("calendar.current.day"); --Debug.console("getCurrentDateinMinutes; nDays =", nDays); local nMonths = DB.getValue("calendar.current.month"); --Debug.console("getCurrentDateinMinutes; nMonths =", nMonths); local nYears = DB.getValue("calendar.current.year"); nRoundsinMinutes = convertRoundstoMinutes(rActor); nHoursinMinutes = convertHourstoMinutes(nHours); --Debug.console("getCurrentDateinMinutes; nHoursinMinutes =", nHoursinMinutes); nDaysinMinutes = convertDaystoMinutes(nDays); --Debug.console("getCurrentDateinMinutes; nDaysinMinutes =", nDaysinMinutes); nMonthsinMinutes = convertMonthssnowtoMinutes(nMonths); --Debug.console("getCurrentDateinMinutes; nMonthsinMinutes =", nMonthsinMinutes); nYearsinMinutes = convertYearsnowtoMinutes(nYears); --Debug.console("getCurrentDateinMinutes; nYearsinMinutes =", nYearsinMinutes); nDateinMinutes = nHoursinMinutes + nDaysinMinutes + nMonthsinMinutes + nYearsinMinutes + nMinutes + nRoundsinMinutes; --Debug.console(getCurrentDateinMinutes); return nDateinMinutes; end you can send a number to these functions and either get the difference back or get a true or false statement function isTimeGreaterThan(rActor, sFirst, nCompareBy) --Debug.console("isTimeGreaterThan called, sFirst = " .. sFirst .. ", nCompareBy = " .. nCompareBy .. ";"); local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); local nStartTime = getStartTime(rActor, sFirst); --Debug.console("isTimeGreaterThan, nStartTime = " .. rActor .. ""); local nCurrentTime = getCurrentDateinMinutes(rActor); --Debug.console("isTimeGreaterThan, nCurrentTime = " .. nCurrentTime .. ", nCompareBy = " .. nCompareBy .. ""); local nDifference = nCurrentTime - nStartTime; --Debug.console("isTimeGreaterThan; nDifference = " .. nDifference .. ", nCurrentTime = " .. nCurrentTime .. ", nStartTime = " .. nStartTime .. ""); if nDifference >= nCompareBy then return true; elseif nDifference < nCompareBy then return false; end end function getTimeDifference(rActor, sFirst, nCompareBy) --Debug.console("isTimeGreaterThan called, sFirst = " .. sFirst .. ", nCompareBy = " .. nCompareBy .. ";"); local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); local nRound = DB.getValue(nodeActor, "game.turn", 0); local nStartTime = DB.getValue(nodeActor, "" .. sFirst .. ".starttime", 0); --Debug.console("getTimeDifference; nStartTime = DB.getValue(nodeActor, " .. sFirst .. ".starttime, 0) = " .. DB.getValue(nodeActor, "" .. sFirst .. ".starttime", nStartTime) .. ""); local nCurrentTime = getCurrentDateinMinutes(); --Debug.console("getTimeDifference, nCurrentTime = " .. nCurrentTime .. ""); local nDifference = nCurrentTime - nStartTime; --Debug.console("getTimeDifference, nDifference = " .. nDifference .. ", nCurrentTime = " .. nCurrentTime .. ", nStartTime = " .. nStartTime .. ""); return nDifference; end
Last edited by pr6i6e6st; May 13th, 2020 at 18:27.
-
May 13th, 2020, 18:06 #27
these are the conversion scripts
Code:function convertRoundstoMinutes(rActor) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); local nRounds = DB.getValue("combattracker.round", 0); local nSecondsperRounds = nRounds * DB.getValue(nodeActor, "game.round", 0); local nRoundsinMinutes = convertSecondstoMinutes(nSecondsperRounds); return nRoundsinMinutes; end function convertSecondstoMinutes(nNumber) --Debug.console("convertRoundstoMinutes called, nNumber = " .. nNumber .. ""); local nMinutesTotaled = nNumber / 60; --Debug.console("convertHourstoMinutes, nMinutesTotaled = " .. nMinutesTotaled .. ""); return nMinutesTotaled; end function convertHourstoMinutes(nNumber) --Debug.console("convertHourstoMinutes called, nNumber = " .. nNumber .. ""); local nMinutesTotaled = nNumber * 60; --Debug.console("convertHourstoMinutes, nMinutesTotaled = " .. nMinutesTotaled .. ""); return nMinutesTotaled; end function convertMinutestoHours(nNumber) --Debug.console("convertHourstoMinutes called, nNumber = " .. nNumber .. ""); local nHoursTotaled = nNumber / 60; --Debug.console("convertHourstoMinutes, nHoursTotaled = " .. nHoursTotaled .. ""); return nHoursTotaled; end function convertHourstoDays(nNumber) --Debug.console("convertHourstoDays called, nNumber = " .. nNumber .. ""); local nDaysTotaled = nNumber / 24; --Debug.console("convertHourstoDays, nDaysTotaled = " .. nDaysTotaled .. ""); return nDaysTotaled; end function convertDaystoHours(nNumber) --Debug.console("convertDaystoHours called, nNumber = " .. nNumber .. ""); local nHoursTotaled = nNumber * 24; --Debug.console("convertHourstoDays, nHoursTotaled = " .. nHoursTotaled .. ""); return nHoursTotaled; end function convertMinutestoDays(nNumber) --Debug.console("convertMinutestoDays called, nNumber = " .. nNumber .. ""); local nHoursTotaled = convertMinutestoHours(nNumber); local nDaysTotaled = convertHourstoDays(nHoursTotaled); --Debug.console("convertMinutestoDays, nHoursTotaled = " .. nHoursTotaled .. ", nDaysTotaled = " .. nDaysTotaled .. ""); return nDaysTotaled; end function convertDaystoMinutes(nNumber) --Debug.console("convertDaystoMinutes called, nNumber = " .. nNumber .. ""); local nDaysinHours = convertDaystoHours(nNumber); local nMinutesTotaled = convertHourstoMinutes(nDaysinHours); --Debug.console("convertDaystoMinutes, nDaysinHours = " .. nDaysinHours .. ", nMinutesTotaled = " .. nMinutesTotaled .. ""); return nMinutesTotaled; end function convertMonthtoHours(nNumber) --Debug.console("convertMonthtoHours called, nNumber = " .. nNumber .. ""); local nYear = DB.getValue("calendar.current.year", 0); local nMonth = DB.getValue("calendar.current.month"); --Debug.console("convertMonthtoHours, nMonth = " .. nMonth .. ", nYear = " .. nYear .. ""); nDays = getDaysInMonth(nNumber, nYear, nDays); nHoursTotaled = convertDaystoHours(nDays); --Debug.console("convertMonthtoHours, nDays = " .. nDays .. ", nHoursTotaled = " .. nHoursTotaled .. ""); return nHoursTotaled; end function convertMonthtoMinutes(nNumber) --Debug.console("convertMonthtoMinutes called, nNumber = " .. nNumber .. ""); local nYear = DB.getValue("calendar.current.year", 0); local nDays = DB.getValue("calendar.data.periods.period" .. nNumber .. ".days", 0); --Debug.console("convertMonthtoMinutes, nDays = " .. nDays .. ", nYear = " .. nYear .. ""); nDays = getDaysInMonth(nNumber, nYear, nDays); nMinutesTotaled = convertDaystoMinutes(nDays); --Debug.console("convertMonthtoMinutes, nDays = " .. nDays .. ", nMinutesTotaled = " .. nMinutesTotaled .. ""); return nMinutesTotaled; end function convertYeartoHours(nNumber) --Debug.console("convertYeartoHours called, nNumber = " .. nNumber .. ""); local nYearinDays = 365; bisLeapYear = isLeapYear(nNumber); --Debug.console("convertYeartoHours, nYearinDays = " .. nYearinDays .. ", bisLeapYear = ", bisLeapYear); if bisLeapYear == true then nYearinDays = nYearinDays + 1; --Debug.console("convertYeartoHours, nYearinHours = " .. nYearinHours .. ", nYearinDays = " .. nYearinDays .. ", bisLeapYear = ", bisLeapYear); end nYearinHours = nYearinDays * 24; --Debug.console("convertYeartoHours, nYearinHours = " .. nYearinHours .. ", nYearinDays = " .. nYearinDays .. ""); return nYearinHours; end function convertYeartoMinutes(nNumber) --Debug.console("convertYeartoMinutes called, nNumber = " .. nNumber .. ""); local nYearinHours = convertYeartoHours(nNumber); nYearinMinutes = nYearinHours * 60; --Debug.console("convertYeartoMinutes, nYearinHours = " .. nYearinHours .. ", nYearinMinutes = " .. nYearinMinutes .. ""); return nYearinMinutes; end function convertYearsnowtoMinutes(nYear) --Debug.console("convertYeartoMinutes called, nNumber = " .. nYear .. ""); local nYearCount = 0; local nYearinDays = 365; local nLeapYear = 0; local nDaysTotaled = 0 for i=1,nYear do if nYearCount < nYear then --Debug.console("convertYearsnowtoMinutes, nYearCount = " .. nYearCount .. ", nYear = " .. nYear .. ""); nYearinHours = convertYeartoHours(i); nMinutesTotaled = nMinutesTotaled + convertHourstoMinutes(nYearinHours); nYearCount = nYearCount + 1; --Debug.console("convertYearsnowtoMinutes, nYearinHours = " .. nYearinHours .. ", nMinutesTotaled = " .. nMinutesTotaled .. ", nYearCount = " .. nYearCount .. ""); end end --Debug.console("convertYearsnowtoMinutes, nMinutesTotaled = " .. nMinutesTotaled .. ""); return nMinutesTotaled; end function convertMonthssnowtoMinutes(nMonth) local nCount = 0; local nMinutes = 0; --Debug.console("convertMonthssnowtoMinutes called, nMonth = " .. nMonth .. ""); for i=1,nMonth do if nCount < nMonth then --Debug.console("convertMonthssnowtoMinutes, nCount = " .. nCount .. ", nMonth = " .. nMonth .. ""); nMinutes = convertMonthtoMinutes(nCount) + nMinutes; nCount = nCount + 1; --Debug.console("convertMonthssnowtoMinutes, nMinutes = " .. nMinutes .. ", nCount = " .. nCount .. ""); end end --Debug.console("convertMonthssnowtoMinutes, nMinutes = " .. nMinutes .. ", nCount = " .. nCount .. ""); return nMinutes; end --extra calculations -- function getDaysInMonth(nMonth, nYear, nDays) --Debug.console("getDaysInMonth called, nMonth = " .. nMonth .. ", nYear = " .. nYear .. ", nDays = " .. nDays .. ""); if nMonth == 2 then local nYear = DB.getValue("calendar.current.year", 0); --Debug.console("getDaysInMonth called, nYear = " .. nYear .. ""); if (nYear % 400) == 0 then nVar = 1; --Debug.console("getDaysInMonth called, nVar = " .. nVar .. ", nYear = " .. nYear .. ", (nYear % 400) = " .. (nYear % 400) .. ""); elseif (nYear % 100) == 0 then nVar = 0; --Debug.console("getDaysInMonth called, nVar = " .. nVar .. ", nYear = " .. nYear .. ", (nYear % 400) = " .. (nYear % 400) .. ""); elseif (nYear % 4) == 0 then nVar = 1; --Debug.console("getDaysInMonth called, nVar = " .. nVar .. ", nYear = " .. nYear .. ", (nYear % 400) = " .. (nYear % 400) .. ""); end else nVar = 0; end nDays = nDays + nVar; --Debug.console("getDaysInMonth called, nVar = " .. nVar .. ", nYear = " .. nYear .. ", nDays = " .. nDays .. ""); return nDays; end function isLeapYear(nYear) return nYear%4==0 and (nYear%100~=0 or nYear%400==0) end
-
May 13th, 2020, 18:11 #28
these are the handlers i set on my clock adjusters to get an accurate change of time, rather than looking at minutes and hours and days and months and years.
Code:function onInit() DB.addHandler("calendar.dateinminutes", "onUpdate", onTimeChanged); end function onTimeChanged() local rActor = ActorManager.resolveActor(window.getDatabaseNode()); CharManager.onRadiationTimeChange(rActor, nRound); end
Code:we check if we're in radiation or not by the toggle on the character sheet function isInRadiation(rActor) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); Debug.console("isInRadiation Called;"); if DB.getValue(nodeActor, "radiation.zone", 0) == 1 then return true; else return false; end end we get how strong the radiation is based on the buttoncycler on the character sheet when we are irradiated function getRadiationStrength(rActor) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); Debug.console("getRadiationStrength Called;"); return DB.getValue(nodeActor, "radiation.strength", 0); end we see if our radiation has gone up or down in points and either roll for damage or roll for healing function checkRadiation(rActor) Debug.console("checkRadiation Called;"); local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); local PermRads = DB.getValue(nodeActor, "radiation.show", 0); local RadMax = DB.getValue(nodeActor, "radiation.minval", 0); local Rads = DB.getValue(nodeActor, "radiation.points", 0); local RadStrength = getRadiationStrength(rActor); local isInRadiation = isInRadiation(rActor); local NewRadiationCheck = Rads; local OldRadiationCheck = DB.getValue(nodeActor, "radiation.oldcheck", 0); Debug.console("checkRadiation; PermRads = " .. NewRadiationCheck .. ", NewRadiationCheck = " .. PermRads .. ", RadMax = " .. RadMax .. ", Rads = " .. Rads .. ", RadStrength = " .. RadStrength .. ""); if OldRadiationCheck == nil then OldRadiationCheck = NewRadiationCheck; end if NewRadiationCheck < OldRadiationCheck then local RadiationDifference = OldRadiationCheck - NewRadiationCheck; throwRadiationHealDice(rActor, RadiationDifference); elseif NewRadiationCheck > OldRadiationCheck then throwRadiationDamageDice(rActor); end local OldRadiationCheck = DB.getValue(nodeActor, "radiation.points", 0); DB.setValue(nodeActor, "radiation.oldcheck", "number", OldRadiationCheck); Debug.console("checkRadiation ;OldRadiationCheck = " .. OldRadiationCheck .. ""); end we increase our radiation points function increaseRadiation(rActor, nNumber) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); for i=1,nNumber do if DB.getValue(nodeActor, "radiation.points", 0) < DB.getValue(nodeActor, "radiation.minval", 0) then RadiationAmount = DB.getValue(nodeActor, "radiation.points", 0) + 1; DB.setValue(nodeActor, "radiation.points", "number", RadiationAmount); end end local OldRadiationCheck = DB.getValue(nodeActor, "radiation.points", 0); DB.setValue(nodeActor, "radiation.oldcheck", "number", OldRadiationCheck); end we decrease our radiation points function decreaseRadiation(rActor, nNumber) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); nCount = 0; for i=1,nNumber do if DB.getValue(nodeActor, "radiation.points", 0) > 0 then RadiationAmount = DB.getValue(nodeActor, "radiation.points", 0) - 1; DB.setValue(nodeActor, "radiation.points", "number", RadiationAmount); nCount = nCount + 1; end end local OldRadiationCheck = DB.getValue(nodeActor, "radiation.points", 0); DB.setValue(nodeActor, "radiation.oldcheck", "number", OldRadiationCheck); end time has changed because of the handlers, lets see what we should do function onRadiationTimeChange(rActor) Debug.console("onRadiationTimeChange Called;"); local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); local PermRads = DB.getValue(nodeActor, "radiation.show", 0); local RadMax = DB.getValue(nodeActor, "radiation.minval", 0); local Rads = DB.getValue(nodeActor, "radiation.points", 0); local RadStrength = getRadiationStrength(rActor); local isInRadiation = isInRadiation(rActor); local nShift = DB.getValue(nodeActor, "game.shift", 0); local nTurn = DB.getValue( "game.turn", 0); local nRound = DB.getValue(nodeActor, "game.round", 0); local sFirst = "radiation"; Debug.console("checkRadiation; PermRads = " .. PermRads .. ", RadMax = " .. RadMax .. ", Rads = " .. Rads .. ", RadStrength = " .. RadStrength .. ""); if RadStrength == 0 then Compareby = convertHourstoMinutes(nShift); Debug.console("onRadiationTimeChange Compareby = " .. Compareby .. ""); elseif RadStrength == 1 then Compareby = nTurn; Debug.console("onRadiationTimeChange Compareby = " .. Compareby .. ""); elseif RadStrength == 2 then Compareby = convertSecondstoMinutes(nRound); Debug.console("onRadiationTimeChange Compareby = " .. Compareby .. ""); end if isInRadiation == true then if CharManager.isTimeGreaterThan(rActor, sFirst, Compareby) == true then Debug.console("onRadiationTimeChange timeIsGreaterThan = " .. Compareby .. ""); DB.setValue(nodeActor, "radiation.oldcheck", "number", Rads); increaseRadiation(rActor, 1); setStartTime(rActor, sFirst); Debug.console("onRadiationTimeChange isInRadiation"); checkRadiation(rActor); end elseif isInRadiation == false then if CharManager.isTimeGreaterThan(rActor, sFirst, convertHourstoMinutes(nShift)) == true then DB.setValue(nodeActor, "radiation.oldcheck", "number", Rads); decreaseRadiation(rActor, 1); setStartTime(rActor, sFirst); Debug.console("onRadiationTimeChange isInRadiation"); checkRadiation(rActor); end end end throw them dice! function throwRadiationDamageDice(rActor) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); Debug.console("throwRadiationHealDice Called;"); local RadiationDamage = Interface.getString("chatmessage_RadiationDamage"); local StateTime = CalendarManager.getCurrentTimeString() local description = "" .. StateTime .. ": " .. RadiationDamage .. ":"; local nValue = DB.getValue(nodeActor, "radiation.points", 0) + DB.getValue(nodeActor, "radiation.show", 0) local nTotal = DB.getValue(nodeActor, "radiation.points", 0).."dB"; local aDice, nMod = StringManager.convertStringToDice(nTotal); local bDescNotEmpty = true; local sStackDesc, nStackMod = ModifierStack.getStack(bDescNotEmpty); local modifierDice = nStackMod; local Negate = 0; if nValue > 0 then for i=1,nValue do table.insert(aDice, "dB"); end else for i=1,-nValue do table.remove(aDice); end end if not User.isHost() then Comm.throwDice( "dice", aDice, Negate, description); end end function throwRadiationHealDice(rActor, nValue) local sActorType, nodeActor = ActorManager.getTypeAndNode(rActor); Debug.console("throwRadiationHealDice Called;"); local RadiationDamage = Interface.getString("chatmessage_CheckRadPerm"); local StateTime = CalendarManager.getCurrentTimeString() local description = "" .. StateTime .. ": " .. RadiationDamage .. ":"; local nTotal = nValue.. "dS"; local aDice, nMod = StringManager.convertStringToDice(nTotal); local bDescNotEmpty = true; local sStackDesc, nStackMod = ModifierStack.getStack(bDescNotEmpty); local modifierDice = nStackMod; local Negate = 0; if nValue > 0 then for i=1,nValue do table.insert(aDice, "dS"); end else for i=1,-nValue do table.remove(aDice); end end if not User.isHost() then Comm.throwDice( "dice", aDice, Negate, description); end end
Code:<label name="currenthour"> <anchored position="insidetopleft" width="20"> <left anchor="left" offset="20" /> <top offset="8" /> </anchored> <frame name="fieldlight" offset="7,5,7,5" /> <stateframe> <hover name="fieldfocus" offset="7,5,7,5" /> </stateframe> <font>calendarbold</font> <color>000000</color> <center /> <tooltip textres="desktop_currenthour_tooltip" /> <script> function onInit() DB.addHandler("calendar.current.hour", "onUpdate", onSourceChanged); DB.addHandler("calendar.current.day", "onUpdate", onSourceChanged); nDay = DB.getValue("calendar.current.day"); onSourceChanged(); end function onClose() DB.removeHandler("calendar.current.hour", "onUpdate", onSourceChanged); DB.removeHandler("calendar.current.day", "onUpdate", onSourceChanged); end function onSourceChanged() local nHour, sPhase = CalendarManager.getDisplayHour(); setValue(string.format("%2d", nHour)); window.currentphase.setValue(sPhase); if nDay ~= DB.getValue("calendar.current.day") then CalendarManager.outputDate(); end nDay = DB.getValue("calendar.current.day"); end function onWheel(n) if not Input.isControlPressed() then return false; end CalendarManager.adjustHours(n); local nDateinMinutes = CharManager.getCurrentDateinMinutes(); DB.setValue("calendar.dateinminutes", "number", nDateinMinutes); return true; end </script>
Last edited by pr6i6e6st; May 13th, 2020 at 18:50.
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks