PDA

View Full Version : iSing



Drunken Durfin
08-27-2010, 01:37 AM
I just uploaded iSing to the Lich repo.

Three options:


;iSing - just sings to whatever you have in your right hand
;iSing bot - starts an autoloresinging bot. Someone hands you something, you sing to it, recite what the loresong is, give item back.
;iSing log - sings to whatever is in your hand, all loresong info is appeneded to iSing-LOG.txt in your Lich/Scripts folder.

Oh...and there is ;iSing help too, prints what is above.

~Ifor Get, tone deaf bard of Shattered

Anebriated
08-27-2010, 02:01 AM
any plans to add in gemsinging?

Shattered Dreamer
08-27-2010, 02:18 AM
Don't do it, it's a trap!

Anebriated
08-27-2010, 02:26 AM
http://images.myspace.drewpydraws.com/its-a-trap.jpg

Shattered Dreamer
08-27-2010, 02:38 AM
http://images.myspace.drewpydraws.com/its-a-trap.jpg


omg theres two sets of toesies!

Drunken Durfin
08-27-2010, 09:00 AM
any plans to add in gemsinging?

Would not be that big a deal, I've already got some solid code that I have used for that for a few years. Maybe I'll even do a GUI so you can select what level to stop singing at...

Jace Solo
08-27-2010, 10:35 AM
You'd be the man! Not that you aren't already

DaCapn
08-27-2010, 12:24 PM
Nice. Just one question, though: Are you Steve Jobs?

Drunken Durfin
08-30-2010, 12:12 AM
Nice. Just one question, though: Are you Steve Jobs?

Nope. The "i" at the beginning of all my new scripts is for "Ifor Get" who is my main char in Shattered.

Drunken Durfin
08-30-2010, 03:17 PM
1.1 released

Minor problem with the BOT and LOG features fixed.

Simutronics has fixed the RECITE bug that caused server crashes. Now, if you recite too much info you get this:



...
You sense that the pink dreamstone earcuff will crumble into dust after its last enhancive charge has been expended.
{cough} {cough}..."

Ifor just couldn't recite that much in one breath.

I'll be working in a bit to check the length of the RECITE so that when in BOT mode it will not cut off the last bit of the result. If I have time I'll work in gem-singing too. No promises though, got a lot of RL stuff to do over the next couple of days.

BriarFox
08-30-2010, 03:22 PM
This script is awesome.

Drew
08-30-2010, 04:32 PM
Yeah the recite fix would be most excellent. I really like this script.

awol0509
08-30-2010, 06:02 PM
^ ditto to that drewcifer.

Deathravin
08-30-2010, 06:15 PM
You also need to make it so it won't try to send too much data anyway... I've had some really big data sets crash my FE. Maybe it's just a wizard thing, but it's funny to see. I got away with 7 lines per recite, haven't have a problem yet.

As I said in the Officials; I really like the logging part. Real good idea; thumbs up.

Drunken Durfin
08-30-2010, 07:58 PM
Modified the LOG feature a bit.

Now at the beginning of each item sung to for LOG entries, the item full description is entered after "===\n" so as to better break up the information.

Example:


===
a glittering imflass earcuff
As you sing, you feel a faint resonating vibration from the imflass earcuff in your hand, and you learn something about it...;This is a small item, under a pound. In your best estimation, it's worth about 3,000 silvers. You can also tell that there is some type of metal in the structure of the imflass earcuff.
As you sing, you feel a faint resonating vibration from the imflass earcuff in your hand, and you learn something about it...;You sense a faint aura of magic around the imflass earcuff. From the pitch of the vibration you determine that the purpose of the earcuff is to cast a spell or perform some magical purpose.
As you sing, you feel a faint resonating vibration from the imflass earcuff in your hand...;From the rapid vibrations of the imflass earcuff, you determine it has no spell within it now, but could be imbedded with one, in the proper hands. You estimate that it can contain an average amount of mana.
As you sing, you feel a faint resonating vibration from the imflass earcuff in your hand...;You sense that the imflass earcuff will persist after its last magical charge has been expended.
===
an alexandrite inset eonake ring
As you sing, you feel a faint resonating vibration from the inset eonake ring in your hand, and you learn something about it...;This is a small item, under a pound. In your best estimation, it's worth about 150,000 silvers. You can also tell that there is some type of metal in the structure of the inset eonake ring.
As you sing, you feel a faint resonating vibration from the inset eonake ring in your hand, and you learn something about it...;You sense a faint aura of magic around the inset eonake ring. You sense that this is some type of holy item. From the pitch of the vibration you determine that the purpose of the ring is to cast a spell or perform some magical purpose. Also, it seems to have some sort of enhancive properties.
As you sing, you feel a faint resonating vibration from the inset eonake ring in your hand...;From the rapid vibrations of the inset eonake ring, you determine it has no spell within it now, but could be imbedded with one, in the proper hands. You estimate that it can contain an average amount of mana.;The ring resonates with your voice, indicating that it enhances its owner in the following ways:;It provides a bonus to Spirit Mana Control Bonus.;This enhancement may not be used by adventurers who have not trained 6 times.;It provides a bonus to Physical Fitness Bonus.;This enhancement may not be used by adventurers who have not trained 14 times.;It provides a bonus to Dodging Bonus.;This enhancement may not be used by adventurers who have not trained 3 times.;It provides a bonus to Polearm Weapons Bonus.;This enhancement may not be used by adventurers who have not trained 3 times.;You think that you could probably find out something more about the ring's enhancive properties if you tried.
As you sing, you feel a faint resonating vibration from the inset eonake ring in your hand...;The magical strength of this item is strong. It could probably handle the imbedding of an entirely new spell, if handled with care.;The ring resonates with your voice, indicating that it enhances its owner in the following ways:;It provides a bonus of 3 to Spirit Mana Control Bonus.;This enhancement may not be used by adventurers who have not trained 6 times.;It provides a bonus of 6 to Physical Fitness Bonus.;This enhancement may not be used by adventurers who have not trained 14 times.;It provides a bonus of 2 to Dodging Bonus.;This enhancement may not be used by adventurers who have not trained 3 times.;It provides a bonus of 2 to Polearm Weapons Bonus.;This enhancement may not be used by adventurers who have not trained 3 times.;The ring looks to have a lot of charges remaining.;You sense that the inset eonake ring will persist after its last enhancive charge has been expended.;You sense that the inset eonake ring will persist after its last magical charge has been expended.

Everyone can thank Liagala for giving me crap via IM for not doing this the first time around.

p.s. no, the ring is NOT for sale.

Vagabondbard
08-31-2010, 04:56 AM
I have this macroed and this is better.

Now what would be even cooler to add (imo) is ;Ising1 2 3 4 depending on what message you might want to get.

Or be specific

:ising lock/special ability/purpose whatever.


GBB

Drunken Durfin
08-31-2010, 09:21 AM
My goal here is as little typing as possible. In case you have not noticed the trend, I'm lazy.

But, you are more than welcome to modify the code to suit your purposes, that is the beauty of Lich. Just in case you are not familiar with Ruby/Lich, here is what you are going to have to do:

Add the line:

elsif script.vars[1].downcase == 'ability'
just before the last line that reads "end".

Then follow with this:

fput "loresing #{item} that I hold;let your special ability now be told"

That should get you started. Just wash/rinse/repeat for the other parameters you want. If you get stuck feel free to shoot me a PM or IM DrunkenDurfin.

Lumi
09-01-2010, 12:36 PM
Very impressive script, Durfin!

Drunken Durfin
09-03-2010, 12:16 AM
Okay, so if your item has a loresong that is over a certain amount of characters, RECITE chokes. Example:

A pearl and aquamarine bracer
"As you sing, you feel a faint resonating vibration from the aquamarine bracer in your hand...
The bracer resonates with your voice, indicating that it enhances its owner in the following ways:
It provides a bonus of 4 to Influence.
This enhancement may not be used by adventurers who have not trained 7 times.
It provides a bonus of 2 to Dodging Bonus.
This enhancement may not be used by adventurers who have not trained 3 times.
It provides a bonus of 3 to Dexterity.
This enhancement may not be used by adventurers who have not trained 6 times.
The bracer looks to have a huge number of charges remaining.
{cough} {cough}..."

Even more fun, if it is really over the char count, it logs you out of GS. This is how they "fixed' the RECITE bug that crashed the server.

So, to get around this, if an item's loresong is over 600 characters, instead of RECITE, it uses SAY. Yeah, spammy as hell, but you have a bard bot that is giving you the goods on your item.

I'm going to read my RUBY book tonight instead of my new JAVA book, maybe I'll find a better way to handle this little issue.

Deathravin
09-03-2010, 12:41 AM
def sns_recite(itemdata)
this = 0
recite = ""
itemdata.each { |datt|
if datt !~ /^\[.+\]\-.+\".+\"$/
recite += "#{datt};"
this += 1
end
if this > 6
fput "recite #{recite}"
recite = ""
this = 0
end
}
fput "recite #{recite}" if this > 0
end

There's still a chance it'll be too many characters but it's how I did it.

Drunken Durfin
09-03-2010, 12:46 AM
Ahhh...I'll give that a shot later.

Danical
09-03-2010, 01:01 AM
Why not just put all the info into a hash to condense the number of characters a ton? Then just report out what you need.



itemHash = {
'weight' => 0.0,
'cost' => 23493948,
'sanct' => nil,
'enhancive' => [ [ 'Influence', 'bonus', 4 ], [ 'Strength', 'stat', 5] ],
'charges' => 'innumerable'
'slot1' => 'crit weighted'
'slot2' => 'permablessed'
}

Gibreficul
09-03-2010, 01:29 PM
any plans to add in gemsinging?

what's wrong with gibs_purify.lic?

Buckwheet
09-03-2010, 01:49 PM
what's wrong with gibs_purify.lic?

Nothing, it works great!

Drunken Durfin
09-03-2010, 02:36 PM
what's wrong with gibs_purify.lic?

I dunno...maybe:

One script to rule them all.

Lumi
09-03-2010, 07:27 PM
Unrelated to the thread, but I'm curious...where'd your avatar come from, Durfin? Is that a commission from one of the local 'stoner artists?

Danical
09-03-2010, 07:38 PM
Looks like warhammer.

Drunken Durfin
09-05-2010, 11:55 PM
Unrelated to the thread, but I'm curious...where'd your avatar come from, Durfin? Is that a commission from one of the local 'stoner artists?

Warhammer. I still have my pre-order box sitting on the desk unopened. Have to get around to that someday.