• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[TFS 1.2] Modal Potion Buyer Lever 2.0

strutZ

Australian OT Member {AKA Beastn}
Joined
Nov 16, 2014
Messages
1,391
Solutions
7
Reaction score
550
Hello Otland!
I have made an easy to use buy potion lever/item whatever i'm not your mum... it uses @Non Sequitur modal window system which can be found HERE

You will have to install that in order to be able to use this system.
1f16ceaa01d71f230046b9a45d86fc99.png


Information on the system
It has an easy config section for you to customize it how you would like it! You just need to fill out the config table found in the action script (pictured below)
Code:
-- Config
   titleMsg = "Choose your Potion",
   mainMsg = "Please select how many potions you would like to buy.",
   moneyMsg = "You do not have enough money!", -- This is the message the player will recieve when he does not have enough money.
   capacityMsg = "I need more cap", -- This is the message the player will recieve when he does not have enough capactiy.
   buyMsg = "You have bought ", -- This is the message the player will recieve when he succesfully buys.
-- End Config

Installation

1)
Install the modal window helper HERE

2) Register the script in /data/actions/actions.xml by adding this line (Replacing "ITEMID" with the item you want to use: (Note you can use an action ID aswell)
Code:
    <action itemid="ITEMID" script="buy_potions.lua"/>
Code:
    <action actionid="ACTIONID" script="buy_potions.lua"/>
3) Create a new text document in /data/actions/scripts and name it "buy_potions.lua" and paste the following:
http://pastebin.com/KbgcJmGv
4) Add the following line to your global.lua:
Code:
dofile('data/lib/buy_potions.lua')
5) Create a new text document in /data/lib/ and name it "buy_potions.lua" and paste the following:
http://pastebin.com/uA2nyjyR

Enjoy =)

Thanks to
@MatheusMkalo
 
Last edited:
Hi, any way to make it sell backpack of potions/runes instead? Seems a little bit more useful.

Btw already tested the current script and works like a charm. Great Job.
 
How can i change this so i can buy items or Runes and no Potions?

Repp for you
 
Back
Top