Legendary Tales Official Website
News Search:
Home · Articles · Downloads · Discussion Forum · RegisterJuly 29 2010 14:23:28
Navigation
Home
Articles
Downloads
Discussion Forum
Web Links
News
Contact Me
Screenshots
Search
Login
Username

Password

Save



I forgot my password.

Why register?
Newsletter
Subscribe now to receive important news, game releases and site updates
Buy 3 Skulls only $9.99


Download a demo

Full version download immediately after purchase!

You can use any credit card.

Visa Mastercard American Express Discover
Affiliates
You can now offer your support and also make money by selling 3 Skulls RPG. You receive 30% commision per sale. If you do not want to let this opportunity pass then act now and register for free.

You will get your own affiliate Control Panel from where you can generate the links to put on your webpages and monitor your generated sales.

Affiliate Registration
Relevant Content
A Custom Skill Script by JSB
//When used, it will put it's user's mana to 0 and
//create a random item, type of which depends on
//the user's skill level. There is also a change
//of failure. At skill level 6, the skill may
//create healing potions with 50% change of failure.
//At level 12, it may produce healing potions or
//poison pastes with 33% change of failure. At level
//18 it may produce healing potions, poison pastes
//or potions which make the drinker go berserk,
//giving +2 to melee attack and damage, but
//reducing 1 point from melee armor, with 25% change
//of failure. At level 24, it may produce healing
//potions, poison pastes, berserk potions or
//antidotes which purge all poison immediatly and
//without any change of not working, with 20% change
//of failure.

UseLib("def.js");

//Loaded javascript library for SetValue and
//GetValue commands.

//Defining functions that the script at the end
//of the file will call to create items.
//We'll take the last function for an example.

function SkillSix(){
i = Rnd(1,2);
if ( i == 1){
AddItem(9001013);
Echo("\You make a healing potion.")
Echo("\n~A healing potion has been added to your inventory.")
}
else if ( i == 2){
Echo("\You fail to make any items.")
}
return true;
}

function SkillTwelve(){
i = Rnd(1,3);
if ( i == 1){
AddItem(9001013);
Echo("\You make a healing potion.")
Echo("\n~A healing potion has been added to your inventory.")
}
else if ( i == 2){
AddItem(9001012);
Echo("\You make a poison paste.")
Echo("\n~A poison paste has been added to your inventory.")
}
else if ( i == 3){
Echo("\You fail to make any items.")
}
return true;
}

function SkillEighteen(){
i = Rnd(1,4);
if ( i == 1){
AddItem(9001013);
Echo("\You make a healing potion.")
Echo("\n~A healing potion has been added to your inventory.")
}
else if ( i == 2){
AddItem(9001012);
Echo("\You make a poison paste.")
Echo("\n~A poison paste has been added to your inventory.")
}
else if ( i == 3){
AddItem(9001015)
Echo("\You make a berserk potion.")
Echo("\n~A berserk potion has been added to your inventory.")
}
else if ( i == 4){
Echo("\You fail to make any items.")
}
return true;
}

function SkillTwentyFour(){
i = Rnd(1,5); //Roll random number: 1-5
if ( i == 1){ //If the number is 1,
AddItem(9001013); //Make a healing potion.
Echo("\You make a healing potion.")
Echo("\n~A healing potion has been added to your inventory.")
}
else if ( i == 2){
AddItem(9001012); //If it's 2, make a poison paste.
Echo("\You make a poison paste.")
Echo("\n~A poison paste has been added to your inventory.")
}
else if ( i == 3){
AddItem(9001015) //If it's 3, make a... You get the idea.
Echo("\You make a berserk potion.")
Echo("\n~A berserk potion has been added to your inventory.")
}
else if ( i == 4){
AddItem(9001014)
Echo("\You make an antidote.")
Echo("\n~An antidote has been added to your inventory.")
}
else if ( i == 5){ //In case of 5, don't make any items.
Echo("\You fail to make any items.")
}
return true;
}

function OnExecute(){ //When the skill is used
v = Sender.SkillValue("Item Making"); //get the skill value
m = Sender.GetValue(32); //and the mana value of the player.
if (m < 10){ //If mana is less than 10, the skill will do nothing.
Echo("\You do not have enought mana to use this skill.")
}
else if (v < 6){ //Same if the skill value is less than 6.
Echo("\You are not skilled enought to make items.")
}
else if (v < 12){ //If skill value is less than 12 (but more than 6, if it is less, this code will be ignored),
Sender.SetValue(32,0,-1); //set the character's mana to 0
SkillSix(); //and trigger function SkillSix.
}
else if (v < 18){ //Same as above, only with slightly
Sender.SetValue(32,0,-1); //different numbers, and
SkillTwelve(); //function SkillTwelve, you get the picture.
}
else if (v < 24){
Sender.SetValue(32,0,-1);
SkillEighteen();
}
else if (v == 24){
Sender.SetValue(32,0,-1);
SkillTwentyFour();
}
}
Comments
No Comments have been Posted.
Post Comment
Please Login to Post a Comment.
Ratings
Rating is available to Members only.

Please login or register to vote.

Awesome! Awesome! 0% [No Votes]
Very Good Very Good 100% [1 Vote]
Good Good 0% [No Votes]
Average Average 0% [No Votes]
Poor Poor 0% [No Votes]
RSS Newsfeed
King's Island II
Isometric action RPG
Dragon Age Journeys
Flash version of Dragon Age
Gemstone Dragon
Isometric flash RPG
Fantasy Kommander
Flash miniature RPG game
Troll's Rage
Platform RPG
Sin Mark
Action Fantasy Game
King's Island
Isometric Flash RPG
Zelda Classic
Zelda classic RPG for Flash
Seeds Of Darkness
Mardek
Top-down classic RPG
 
Darkness Springs
Isometric Action RPG
Murloc
Fun WoW based RPG game
Monster's Den
Classic dungeon crawl RPG
Dungeon Defender
Strategy RPG game
A PBBG Game
Legendary Tales Online is a PBBG.
Suggestions
Copyright www.legendarytales.com © 2001 - 2010

Terms Of Service Privacy Policy