RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

daat99's Token System without long save times.

daat99

Moderator
Staff member
Ryan2005R said:
I didt know you couldt ask for help:confused:
You can ask for help and I told you what you need to do.
You can't ask on how to do it in the script release forum, learning where to ask is the number 1 thing if you want to get help.
 

Ryan2005R

Wanderer
daat99 said:
You can ask for help and I told you what you need to do.
You can't ask on how to do it in the script release forum, learning where to ask is the number 1 thing if you want to get help.
Well iam new to these forums sir just asking......And please explain that just alil better? Please sir
And if not here you could talk to me over icq i tried putting u on my list all iam waitting on you to do is accept it =)
 
daat99 said:
Changelog:

21/05/2005 v1.0-1.2 post #55
v1.2
21/05/2005: Fixed a problem with tokens from OWLTR not working as a standalone

v1.1
12/04/2005: Added a method to give tokens to ledger from scripts.

v1.0
29/03/2005: Fixed a problem with safe trash4tokens backpack doesn't open gump in 2d clients (thanx Disillusion).
28/03/2005: Fixed a typo in the token ledger making the min check value 1001 instead of 1000.

27/03/2005 v0.9 post #29
27/03/2005: Make a limit of 1k tokens for checks (can't write less then 1000)
27/03/2005: Added a safe trash4tokens backpack, players can trash everything but they'll get 2-5 tokens for each NOT stackable item (to avoid exploits).

23/03/2005 v0.8 post #19 HOTFIX
23/03/2005: Fixed a mistake in lady luck that reset the reward if updated between drawings.

23/03/2005 v0.7 post #18
23/03/2005: Added option to extract normal tokens from the ledger (for those who like to see it).
23/03/2005: Fixed several bugs in the lottery system and added some functions.
21/03/2005: fixed some typos in the lottery system.

06/03/2005 v0.6 post #17
06/03/2005: Added Lady Luck, new token lottery system.
05/03/2005: Made the code use less cpu using finditembytype instead of foreach item.

16/02/2005 v0.5
16/02/2005: In the last release I fixed a compatibility issue with the original vendor stone and made it not compile on its own. sorry about that, it's fixed now can work solo and with the original.

15/02/2005 v0.4
15/02/2005: Fixed another compatibility issue with token stone and the original vendor stone. I hope it's the last 1.

14/02/2005 v0.3
14/02/2005: Rewrote the backward compatibility code in much better way (ThanX UOT for your help).
13/02/2005: added NOt blessed LootTokenCheck in case anyone want to add tokens to monsters loot manually.
(if they get 2.15bil it'll set negative value ==> GM I LOST MY TOKENS).
13/02/2005: added multiple checks to make sure players won't get over 2,000,000,000 tokens in 1 ledger.

13/02/2005 v0.2 post #5
13/02/2005: Added an option to add old tokens to the token ledger.
13/02/2005: Renamed "Token Stone" to "Token Vendor Stone" to avoid compatibility problems with some older token systems.

11/02/2005 v0.1 post #1
11/02/2005: after close to 22 hours of scripting finished daat99's Token System
10/02/2005: got permission from Viago to start working on token system after seeing his post.

Credits to daat99's Token System v0.1 Runuo 1.0.0:
Took the "invisible tokens" idea from Viago's token system (ThanX a lot for your permission Viago ;) )
Took the Ultimate Prize Stone and modded it to accept daat99tokens as default (from the token ledger) also fixed a few things.
Thanx to Murzin for all the english help :)


Description:
Token System:
A token system with much less lag then you used to :)
The tokens are stored as a variable in a "token ledger" which make it without the endless lag of countless of tokens around the world.
Tokens are given based on a complex formula that takes into acount most of the factors that make monsters strong and harder to kill rather then the simple fame == reward and those kinds.
Each token ledger can store up to 2,147,483,647 token (yes over 2 billion, just think about the lag they'll do without it MUAHAHAHA).
The Token Ledger values can be modified by admins ONLY, if a gm want to give someone tokens he'll have to give him a token check.
Each token ledger is protected with the serial number of the character himself so other players can't steal the tokens (they can steal the token ledger, they just can't use the tokens in it).
If for any reason you want to give an existing token ledger to another player then the admin can dclick the ledger and select the new owner for it.
Token ledgers are spawned as "An Empty Token Ledger", that means they don't have owner.
Once a player double click on an empty token ledger the name will be changed to "<player name>'s Token Ledger" and from then on he'll be the only 1 who can use it (it'll reset the tokens on it too, just in case).
The token checks can be used only when they're inside the backpack of the user and they'll only add their value to the token ledger in his pack and if he owns it.
Added LootTokenCheck in case anyone want to add it manually to monsters.
Token Stone:
Token Stone (which is basically the Ultimate Prize Stone by Raelis) When you [add tokenstone in game the currency is auto set to the currency the tokens uses (daat99tokens), you can change the currency to whatever you want, ThanX Raelis for great script :)
Players can make Token Checks when using the token ledger gump (gm's can make them with [add tokencheck #amount#).
Lady Luck Lottery:
Lady Luck is an npc that sell lottery tickets.
Each ticket cost 1k tokens (taken from the players token ledger).
The lottery is set to repeat every 168 hours (can be changed with [props on her).
There will always be a winner and the reward will be half the cost of the tickets sold since the last drawing.
If nobody claimed his reward then the reward will be added to the next drawing reward (half the cost of tickets).
The players can use [lottery to tell them when the next drawing will take place, which ticket won the last drawing and what was the reward.
To claim your reward just drop the ticket on LadyLuck and she'll tell you if you won or not.
In case you won there'll be a nice fireworks above you and you'll get token check and fireworks wand.
Safe Trash 4 Tokens Backpack:
The Safe trash 4 tokens backpack is basically my safe backpack script that give the player 3 minutes to get his stuff out of the pack.
It'll trash everything you put in it but it'll give you a 2-5 tokens reward for every item that is NOT stackable (won't reward bandages\gold etc but it'll delete them).
It'll add the tokens to the player token ledger and show him a message that tell him how much tokens he got and thank him for cleaning the shard.

Pakcage include 3 files:
daat99's Token System.cs This file holds everything you need to have tokens.
daat99's Token System.txt this readme file
Token Stone.cs This file will add vendor stone that use this system tokens (daat99tokens) as default currency (currency can be changed to anything you want). <== This is based on the Ultimate Prize Stone script by Raelis, all credits goes for him ;)

Installation:
1. Place all the files anywhere in **\runuo\scripts\custom\**
2. Restart the server and let your players have fun :)

If you want to give your players tokens for each monster they kill follow step 3:

3. In BaseCreature.cs look for those 2 lines:
Code:
		Titles.AwardFame( ds.m_Mobile, totalFame, true );
		Titles.AwardKarma( ds.m_Mobile, totalKarma, true );
Add just after them this line:
Code:
		GiveTokens.CalculateTokens(ds.m_Mobile, this); // daat99 token system 1/1

P.S.
You will have to give your players the "Token Ledger" and they'll need to dclick it before they can get tokens.
I suggest adding it in charactercreation.cs


P.S.S
The original Ultimate Prize Stone by Raelis can be found here:
http://www.runuo.com/forum/showthread.php?t=40693&highlight=ultimate

Please give him credits for it, I just modded it to fit the token system.

Thanx goes to:



If i try to do That , i can die in the try :(
 

Newbiepdo

Sorceror
Lady Luck

How do I reset Lady Luck, She hands out tickets that say "tIcket # 18182111, I know she hasnt sold that many tickets.
 

daat99

Moderator
Staff member
Newbiepdo said:
How do I reset Lady Luck, She hands out tickets that say "tIcket # 18182111, I know she hasnt sold that many tickets.
The only way is to do [props on her and reset the "Ticket" property.
Keep in mind that there will be duplicate tickets on the next drawing.
 

Newbiepdo

Sorceror
Lady Luck Bug

Ok, My staff and I just figured out theres a apparent bug with her, Thats how the numbers on the tickets have gotten so high. Any ideas Daat? You have always been a great scriptor and helper with your scripts. Thanks for everything you do!
 

daat99

Moderator
Staff member
Newbiepdo said:
Ok, My staff and I just figured out theres a apparent bug with her, all you need is 1000 tokens and you buy tickets and she will give you the lottery tickets and fill your token ledger with 558 million tokens. Thats how the numbers on the tickets have gotten so high. Any ideas Daat? You have always been a great scriptor and helper with your scripts. Thanks for everything you do!
Care to explain exactly HOW it was done?
If I can't duplicate something then I can't fix it.

P.S.
Please send me that exploit details in private and don't post it on the forums, ty.
 

daat99

Moderator
Staff member
Newbiepdo said:
Ok, My staff and I just figured out theres a apparent bug with her, Thats how the numbers on the tickets have gotten so high. Any ideas Daat? You have always been a great scriptor and helper with your scripts. Thanks for everything you do!
That exploit was fixed already at v1.3.
Please update your token system asap.
 

daat99

Moderator
Staff member
Newbiepdo said:
the version you have posted at beginning of this thread is 1.2, could you please provide a link to version 1.3?
Read the first post, the info you need to get it is there.
 

daat99

Moderator
Staff member
RadicalFlower said:
ok i feel stupid.. but i dont see where i can download this system heheh.. i must be going blind...

sorry
Read the first post, it tell you where to get it in HUGE letters.
 

daat99

Moderator
Staff member
RadicalFlower said:
sorry about that :) ... is that the Stand alone token system i dont want the leather or scales and stuff Just the Tokens???
I don't know... what the installation notes, the F.A.Q. and the first post said?
 

daat99

Moderator
Staff member
FireDragon said:
where is the zip for tokens system.
Due to temporary removal of the OWLTR system you can download this only from my website.
Just download the OWLTR and install only the tokens folder ignoring the rest.
 
Top