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
daat99's Token System without long save times.

Hail citizens of RunUO:
As of this date all future releases and updates of daat99's Token System will be released in a standalone folder as part of the OWLTR system in my website and at the following thread:
O.W.L.T.R

The O.W.L.T.R will specify when the Tokens was last updated at the first thread and at each related update, You won't have to download all the O.W.L.T.R. files, just the tokens folder in 4of4.zip file.
I'll still support the Tokens standalone errors\bugs in this thread.

Signing off.. daat99
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:
RunUO Forums: A_Li_N, UOT, ArteGordon, jjarmis, ssalter, Raelis.
Shards: Allure of the Unknown.
 

Erica

Knight
daat99 said:
Changelog:
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:
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).

Also in the pack a 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#).

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.

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. 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.GiveTokensAct(ds.m_Mobile, this); // daat99 token system 1/1
3. Restart the server and let your players have fun :)

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.
very nice good for new shard tho no one really is going to delete there old tokens if they do delete old ones thats going to get plaqyers pisted cause what tokens they got already and also thats lots of work to get rid of the other tokens
 

daat99

Moderator
Staff member
Erica said:
very nice good for new shard tho no one really is going to delete there old tokens if they do delete old ones thats going to get plaqyers pisted cause what tokens they got already and also thats lots of work to get rid of the other tokens
Actually I'm working on an option to integrate the "old" token systems into this 1.
I don't know when I'll finish it (I need to find gump studio first :( ) but when I do it'll be here :)
 

Erica

Knight
daat99 said:
Actually I'm working on an option to integrate the "old" token systems into this 1.
I don't know when I'll finish it (I need to find gump studio first :( ) but when I do it'll be here :)
awesome cant wait if that happens that be great
 

daat99

Moderator
Staff member
v0.2 update
Added option to add old tokens to the token ledger using the gump.
Just select the add button and click on the tokens.
Keep in mind it must be named with varient of "token" and stackable.
Other systems token checks can't be added directly, you'll have to cash them and then add the tokens.

If you have tokens that aren't recognized by this system PLEASE let me know, ty.

Renamed token stone to :token vendor stone" to avoid problems with some systems so please delete the "token stone" from v0.1.
 
Awesome job daat99. the integration of old tokens make this a great system (not that it wasn't already). it will allow established shards to use your system without much trouble.
thanks for the submission!
 

daat99

Moderator
Staff member
Random Person said:
Awesome job daat99. the integration of old tokens make this a great system (not that it wasn't already). it will allow established shards to use your system without much trouble.
thanks for the submission!
ThanX :)
With v0.2 you just need to click add and then select the tokens to add them to the ledger.
Very simple :)

Just 1 note for those of you that use the original prize stone.
AS it is in the original release it doesn't recognized daat99tokens as a currency so you'll have to redo your vendor stones with the token vendor stone.

Also once you added the old tokens to the ledger you can't reverse it.
If you want to switch back you'll have to make the old tokens manually using whatever command you have to make them.
Just tell your players to make a check using the tokens in his ledger and replace it with your old token system check.
 

daat99

Moderator
Staff member
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.
 

daat99

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

daat99

Moderator
Staff member
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.
 

No-one

Wanderer
daat99 great script as all ways u make good stuff . im having a minor prob i have done every thing that u said to do and i can get the checks ,stone and the leger but i addeed the line to get tokens to drop on monsters and re started. checked the monset and no tokens do i hve to go and changet soem thing in the lootpack.cs??
 

daat99

Moderator
Staff member
No-one said:
daat99 great script as all ways u make good stuff . im having a minor prob i have done every thing that u said to do and i can get the checks ,stone and the leger but i addeed the line to get tokens to drop on monsters and re started. checked the monset and no tokens do i hve to go and changet soem thing in the lootpack.cs??
The tokens won't be on the monsters.
If you have a ledger with your name in your backpack (like "Joes token ledger") it'll add the tokens to the ledger when you kill something.
Just open it write how much tokens you have kill a cow open it again and you'll see that you got 1 more token.
 

daat99

Moderator
Staff member
06/03/2005 v0.6 update:
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.
 

daat99

Moderator
Staff member
23/03/2005 v0.7 update:
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.
 

daat99

Moderator
Staff member
23/03/2005 v0.8 HOTFIX:
23/03/2005: Fixed a mistake in lady luck that reset the reward if updated between drawings.
 

RANCID77

Wanderer
Just wanted to say aweasome script me and some friends have allways been gms or admins on other shards and we finally broke down and started our own like 2 weeks ago and absolutely love this addition keep up the good work and keep em coming
 
Top