L2Tower Discord Let's keep the community alive with discord. Discussions about plugins and scripts L2Tower Discord

Thread Closed 
 
Thread Rating:
  • 6 Vote(s) - 2.83 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Enchant not blessed?
Author Message
jnorman Offline
Gremlin
*

Posts: 6
Joined: Dec 2012
Reputation: 0
Version: 1.4.1.106
Post: #1
Enchant not blessed?

hi, was wondering if you can enchant with l2tower but not use blessed scrolls just normal ones?
01-20-2013 19:17 PM
Find all posts by this user
Hebdzik Offline
Tester

Posts: 1,235
Joined: Aug 2011
Reputation: 265
Version: 1.4.3.143
Post: #2
RE: Enchant not blessed?

yes you can there are more than 2 already made script's on forum. and you have 1 already in you script folder when you upgrade game.

Warning hammer!!! Use Search before you post something
If i hellp you, you can thx me by +1 Reputation
[Image: U63SU]
01-20-2013 20:27 PM
Find all posts by this user
jnorman Offline
Gremlin
*

Posts: 6
Joined: Dec 2012
Reputation: 0
Version: 1.4.1.106
Post: #3
RE: Enchant not blessed?

(01-20-2013 19:17 PM)jnorman Wrote:  hi, was wondering if you can enchant with l2tower but not use blessed scrolls just normal ones?
ok ty but now i try and it says i dont have scrolls but i do have them?
01-20-2013 23:03 PM
Find all posts by this user
TheBl4ckPhoenix Offline
(^.^)
****

Posts: 1,887
Joined: Mar 2012
Reputation: 601
Version: 1.4.3.143
Post: #4
RE: Enchant not blessed?

Maybe modded enchants, if private server..
01-20-2013 23:16 PM
Find all posts by this user
jnorman Offline
Gremlin
*

Posts: 6
Joined: Dec 2012
Reputation: 0
Version: 1.4.1.106
Post: #5
RE: Enchant not blessed?

(01-20-2013 23:03 PM)jnorman Wrote:  
(01-20-2013 19:17 PM)jnorman Wrote:  hi, was wondering if you can enchant with l2tower but not use blessed scrolls just normal ones?
ok ty but now i try and it says i dont have scrolls but i do have them?
modded? and yes it's blackbird server so will the enchant thing work?
01-20-2013 23:17 PM
Find all posts by this user
Hebdzik Offline
Tester

Posts: 1,235
Joined: Aug 2011
Reputation: 265
Version: 1.4.3.143
Post: #6
RE: Enchant not blessed?

well man you have to open this script, put name of enchants, put name of weapon/armor and all in all set it under your needs.

Warning hammer!!! Use Search before you post something
If i hellp you, you can thx me by +1 Reputation
[Image: U63SU]
01-20-2013 23:55 PM
Find all posts by this user
jnorman Offline
Gremlin
*

Posts: 6
Joined: Dec 2012
Reputation: 0
Version: 1.4.1.106
Post: #7
RE: Enchant not blessed?

(01-20-2013 23:55 PM)Hebdzik Wrote:  well man you have to open this script, put name of enchants, put name of weapon/armor and all in all set it under your needs.
-- SCRIPT CONFIGURATION!

item_name = "Skull Edge"
enchant_name = "Scroll: Enchant Weapon (S-Grade)"
blessed_enchant_name = "Blessed Scroll: Enchant Weapon (S-Grade)"
max_enchant = 16
max_safe_enchant = 3
delay = 4000

-- END OF SCRIPT CONFIGURATION

-- HELPER FUNCTIONS
function enchantResult()
return GetEnchantManager():getLastResult()
end

function getItemByName(name, maxenchant)
invList = GetInventory();
for item in invList.list do
if item.Name == name and item.Enchanted < maxenchant then
return item
end
end
end

stats = {}

function registerSuccess(base)
if stats[base] == nil then
stats[base] = { success = 0, failure = 0 }
end
stats[base].success = stats[base].success + 1
end

function registerFailure(base)
if stats[base] == nil then
stats[base] = { success = 0, failure = 0 }
end
stats[base].failure = stats[base].failure + 1
end

function printStatistics()
for i,v in ipairs(stats) do
ShowToClient("Enchant", "[" .. i - 1 .. "->" .. i .. "] Rate: success: " .. v.success .. " / fail: " .. v.failure .." (" .. ( v.success * 100 )/ ( v.success + v.failure ) .. "%)")
end
end

-- MAIN LOOP!

while true do
-- find item for enchanting
item = getItemByName(item_name, max_enchant)
if ( item == nil ) then
ShowToClient("Enchant", "Out of items" )
break
end
-- find proper enchant scroll
enchant = nil
if ( item.Enchanted >= max_safe_enchant ) then
enchant = getItemByName(blessed_enchant_name, 20)
else
enchant = getItemByName(enchant_name, 20)
end

if ( enchant == nil ) then
ShowToClient("Enchant", "Out of enchants")
break
end

GetEnchantManager():setDelay(delay)
GetEnchantManager():setEnchantId(enchant.objectId)
GetEnchantManager():setItemId(item.objectId)
GetEnchantManager():Enchant()

while ( enchantResult() == Enchant.ENCHANT_PENDING ) do
Sleep(200)
end

if ( enchantResult() == Enchant.ENCHANT_SUCCESS ) then
Sleep ( 500 ) -- sleep so item data is updated
item = GetInventory():FindById(item.objectId)
ShowToClient("Enchant", item.Name .. " is now +" .. item.Enchanted);
registerSuccess ( item.Enchanted )
elseif ( enchantResult() == Enchant.ENCHANT_FAILURE ) then
ShowToClient("Enchant", item.Name .. " failed on " .. item.Enchanted .. " -> " .. item.Enchanted+1)
Sleep ( 500 ) -- sleep so item data is updated
registerFailure ( item.Enchanted + 1)
end
printStatistics()
end
ShowToClient("Enchant", "Enchant script finished")
printStatistics()
01-21-2013 00:04 AM
Find all posts by this user
Thread Closed 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  [Need Help] Enchant Script nvnhathuy 1 5,235 03-03-2017 20:07 PM
Last Post: deivuzas1
  Get skill enchant level raid1141 1 4,142 10-15-2015 14:57 PM
Last Post: raid1141
  Auto Enchant Script sone78 3 7,871 11-26-2014 17:20 PM
Last Post: sone78
  Not working Enchant sallabisey 0 2,046 03-28-2014 08:02 AM
Last Post: sallabisey
  Enchant salimonas 0 2,170 06-29-2013 22:25 PM
Last Post: salimonas
  Enchant NaoJogoMais 0 2,982 04-09-2013 21:37 PM
Last Post: NaoJogoMais
  Auto Enchant Armor problems psyhyk 1 3,644 03-28-2013 23:06 PM
Last Post: MtnDew
  Script Enchant Armor ? Farghass 1 6,371 11-22-2012 23:13 PM
Last Post: aniah
  The script to enchant and + 2 stops working what is wrong? xamius55 1 2,836 08-07-2012 19:12 PM
Last Post: AdioZ
Question Auto item enchant problem [Video] AdioZ 4 14,863 08-05-2012 11:06 AM
Last Post: feliperigo



User(s) browsing this thread: 1 Guest(s)