<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.runerealm.org/index.php?action=history&amp;feed=atom&amp;title=Module%3AArceuus_library_book_calculator</id>
	<title>Module:Arceuus library book calculator - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.runerealm.org/index.php?action=history&amp;feed=atom&amp;title=Module%3AArceuus_library_book_calculator"/>
	<link rel="alternate" type="text/html" href="https://wiki.runerealm.org/index.php?title=Module:Arceuus_library_book_calculator&amp;action=history"/>
	<updated>2026-04-30T11:42:09Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.1</generator>
	<entry>
		<id>https://wiki.runerealm.org/index.php?title=Module:Arceuus_library_book_calculator&amp;diff=34414&amp;oldid=prev</id>
		<title>Alex: Created page with &quot;local p = {}  local addCommas = require(&#039;Module:Addcommas&#039;)._add local experience = require(&#039;Module:Experience&#039;) local scaledExperience = require(&#039;Module:ScaledExperience&#039;) local scp = require(&#039;Module:SCP&#039;)._main  function p.buildTable(skill, itemData) 	local ret = mw.html.create(&#039;table&#039;):addClass(&#039;wikitable&#039;):done() 		ret:tag(&#039;tr&#039;):tag(&#039;th&#039;):wikitext(&#039;link=&#039; .. itemData.link .. &#039; &#039; .. itemData.name .. &#039; require...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.runerealm.org/index.php?title=Module:Arceuus_library_book_calculator&amp;diff=34414&amp;oldid=prev"/>
		<updated>2024-10-16T22:59:28Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;local p = {}  local addCommas = require(&amp;#039;Module:Addcommas&amp;#039;)._add local experience = require(&amp;#039;Module:Experience&amp;#039;) local scaledExperience = require(&amp;#039;Module:ScaledExperience&amp;#039;) local scp = require(&amp;#039;Module:SCP&amp;#039;)._main  function p.buildTable(skill, itemData) 	local ret = mw.html.create(&amp;#039;table&amp;#039;):addClass(&amp;#039;wikitable&amp;#039;):done() 		ret:tag(&amp;#039;tr&amp;#039;):tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;&lt;a href=&quot;/index.php?title=File:%27.._itemData.file_.._%27&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;File:&amp;#039;.. itemData.file .. &amp;#039; (page does not exist)&quot;&gt;link=&amp;#039; .. itemData.link .. &amp;#039;&lt;/a&gt; &lt;a href=&quot;/index.php?title=%27_.._itemData.link_.._%27&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;&amp;#039; .. itemData.link .. &amp;#039; (page does not exist)&quot;&gt;&amp;#039; .. itemData.name .. &amp;#039;&lt;/a&gt; require...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
&lt;br /&gt;
local addCommas = require(&amp;#039;Module:Addcommas&amp;#039;)._add&lt;br /&gt;
local experience = require(&amp;#039;Module:Experience&amp;#039;)&lt;br /&gt;
local scaledExperience = require(&amp;#039;Module:ScaledExperience&amp;#039;)&lt;br /&gt;
local scp = require(&amp;#039;Module:SCP&amp;#039;)._main&lt;br /&gt;
&lt;br /&gt;
function p.buildTable(skill, itemData)&lt;br /&gt;
	local ret = mw.html.create(&amp;#039;table&amp;#039;):addClass(&amp;#039;wikitable&amp;#039;):done()&lt;br /&gt;
		ret:tag(&amp;#039;tr&amp;#039;):tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;[[File:&amp;#039;.. itemData.file .. &amp;#039;|link=&amp;#039; .. itemData.link .. &amp;#039;]] [[&amp;#039; .. itemData.link .. &amp;#039;|&amp;#039; .. itemData.name .. &amp;#039;]] required:&amp;#039;):attr(&amp;#039;colspan&amp;#039;, 2):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(addCommas(itemData.data.endActions)):attr(&amp;#039;colspan&amp;#039;, 2):done()&lt;br /&gt;
		&lt;br /&gt;
		ret:tag(&amp;#039;tr&amp;#039;):tag(&amp;#039;th&amp;#039;):wikitext(scp(skill, nil, &amp;#039;yes&amp;#039;)):done()&lt;br /&gt;
		:tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;Start&amp;#039;):done()&lt;br /&gt;
		:tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;End&amp;#039;):done()&lt;br /&gt;
		:tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;Earned&amp;#039;):done()&lt;br /&gt;
		&lt;br /&gt;
		ret:tag(&amp;#039;tr&amp;#039;):tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;Experience&amp;#039;):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(addCommas(itemData.data.startingExp)):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(addCommas(itemData.data.endExp)):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(addCommas(itemData.data.endExp - itemData.data.startingExp)):done()&lt;br /&gt;
		&lt;br /&gt;
		ret:tag(&amp;#039;tr&amp;#039;):tag(&amp;#039;th&amp;#039;):wikitext(&amp;#039;Level&amp;#039;):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(itemData.data.startingLevel):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(itemData.data.endLevel):done()&lt;br /&gt;
		:tag(&amp;#039;td&amp;#039;):wikitext(itemData.data.endLevel - itemData.data.startingLevel):done()&lt;br /&gt;
	&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	local skill = args.skill&lt;br /&gt;
	-- inputType and targetType are either &amp;#039;Level&amp;#039; or &amp;#039;Experience&amp;#039;&lt;br /&gt;
	local inputType, currentLevel, currentExperience = args.inputType, tonumber(args.currentLevel), tonumber(args.currentExperience)&lt;br /&gt;
	local targetType, targetLevel, targetExperience = args.targetType, tonumber(args.targetLevel), tonumber(args.targetExperience)&lt;br /&gt;
	local leagueMultiplier = args.leagueMultiplier or 1&lt;br /&gt;
	&lt;br /&gt;
	-- Get the currentExperience at the current level&lt;br /&gt;
	if(inputType == &amp;#039;Level&amp;#039;) then&lt;br /&gt;
		currentExperience = experience.xp_at_level_unr({args = {currentLevel}})&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Get the targetExperience at the target level&lt;br /&gt;
	if(targetType == &amp;#039;Level&amp;#039;) then&lt;br /&gt;
		targetExperience = experience.xp_at_level_unr({args = {targetLevel}})&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Magic multiplier: 15, Runecraft multiplier: 5&lt;br /&gt;
	local levelMultiplier = (skill == &amp;#039;Magic&amp;#039; and 15 or 5) * leagueMultiplier&lt;br /&gt;
	&lt;br /&gt;
	bookData = scaledExperience.xp_to_xp_actions(currentExperience, targetExperience, levelMultiplier)&lt;br /&gt;
	&lt;br /&gt;
	-- [&amp;#039;data&amp;#039;] is a table of 5 values endExp, endActions, endLevel, startingExp, startingLevel&lt;br /&gt;
	itemData = {&lt;br /&gt;
			[&amp;#039;name&amp;#039;] = &amp;#039;Book of arcane knowledge&amp;#039;,&lt;br /&gt;
			[&amp;#039;link&amp;#039;] = &amp;#039;Book_of_arcane_knowledge&amp;#039;,&lt;br /&gt;
			[&amp;#039;file&amp;#039;] = &amp;#039;Book_of_arcane_knowledge.png&amp;#039;,&lt;br /&gt;
			[&amp;#039;data&amp;#039;] = bookData,&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	return p.buildTable(skill, itemData)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	--mw.logObject(frame)&lt;br /&gt;
	local args = frame:getParent().args&lt;br /&gt;
	return p._main(args)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Alex</name></author>
	</entry>
</feed>