mIRC Home    About    Download    Register    News    Help

Print Thread
#171766 28/02/07 07:57 PM
Joined: Feb 2007
Posts: 3
W
wozer83 Offline OP
Self-satisified door
OP Offline
Self-satisified door
W
Joined: Feb 2007
Posts: 3
ive never scripted with irc before and was wondering if anyone out there was willing to help, i need to make a couple of programs for my channel, one of them is to register certain parts of a copied and pasted "log" and keep them stored untill there updated, alos accessed by anyone who types in a certain part of that log to show the rest of it,
e.g.

bob

21 shields live ins farmstown has 12 dogs
3 hours ago

if you typed in bob then
21 shields + 12 dogs would appear with the last update of that.


for the second script i need something similar
buts its a set few lines and it has the name again
e.g.

bob

lost 7 dogs and 11 shields
30 minutes ago

the items have a price with them for each one so
the script would put what "bob" lost away untill someone typed his name up to see whats happened to him, aswell as add up all hes lost for a total amount while showing whats hes lost for e.g.

1 shield = 100
1 dog = 200
11 * 100 = 1100
7 * 200 = 1400

so..

bob
11 shields 1100
7 dogs 1400

total amount 2500


thats what ive been looking around for with help on, i tried doing the basic tutorials which were fine but something like this i dont have a clue where to start i need help from irc scripters

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
First of all, you need to display the exact format that is shown in the channel. This is done best by copy/pasting the line(s) from mIRC into here rather than retyping them. Please also copy the control codes that may be used (ie. hold CTRL when highlighting the text).

Second, you need to make sure that all of the displayed text that needs "stored" maintains the same formatting every time it's displayed. If it changes, you need to explain that.


Invision Support
#Invision on irc.irchighway.net
Joined: Feb 2007
Posts: 3
W
wozer83 Offline OP
Self-satisified door
OP Offline
Self-satisified door
W
Joined: Feb 2007
Posts: 3
* Now talking in #darklordhenry
* Topic is '4,1>=/=\=> 3,1The Dark0rder's *PRIVATE* Chat 8,1-- 12,1Goal by March 11th: 700,000 lead 3,14,1<=/=\=<'
* Set by HENRY-TDO on Sun Mar 04 04:04:00
* ChanServ sets mode: +v covsas
-DarkBot- Welcome to the HENRY-TBH & DarkBot Private Channel!! Type !commands for a list of Darkbot's useful commands.


thats the format in the irc channel.

this is the text that will be copied and pasted in to the irc channel for e.g.

Your Chief of Intelligence dispatches 1 spies to attempt to sabotage 50 of BadGirlTex_LaCN's weapons of type Mithril.
Your spies successfully enter BadGirlTex_LaCN's armory undetected, and destroy 50 of the enemy's Mithril stockpile. Your spies all return safely to your camp.


the text in bold is the text that needs to be stored,

when calling up the information about the player, in this case
BadGirlTex_LaCN

all you would have to type is

"BadGirlTex_LaCNstats"

and the information would come up as
BadGirlTex_LaCN
50 mithril sabotaged

2,500,000 gold total sabbed



____________________________________

name | QTY | Price

Stick | 2 | 200 Gold
Knife | 5 | 1,000 Gold
Staff | 10 | 1,800 Gold
Long Sword | 20 | 3,200 Gold
Lance | 40 | 5,100 Gold
Broadsword | 160 | 16,400 Gold
Steed | 640 | 50,000 Gold
Excalibur | 2,560 | 200,000 Gold
Chariot | 6,000 | 450,000 Gold
Blackpowder Missile | 12,000 | 850,000 Gold
Helmet | 10 | 2,000 Gold
Shield | 20 | 3,200 Gold
Chainmail | 40 | 5,100 Gold
Plate Armor | 160 | 16,400 Gold
Mithril | 640 | 50,000 Gold
Dragonskin | 2,560 | 200,000 Gold
Invisibility Shield | 10,000 | 750,000 Gold

_________________________________________

all the data above is all the possible options there could be for the data stored. the only variable will be the name but once its been inputted it will be stored like the rest of the data.

so again when in the irc channel you want it to save the name and record all the data in bold above, when the data needs to be recalled all you need to type is the name.

another part will be storing the name of the person who copied n pasted the lines

for e.g.

<covsas> Your Chief of Intelligence dispatches 1 spies to attempt to sabotage 50 of BadGirlTex_LaCN's weapons of type Mithril.
<covsas> Your spies successfully enter BadGirlTex_LaCN's armory undetected, and destroy 50 of the enemy's Mithril stockpile. Your spies all return safely to your camp.

the script would record <covsas>.

when someone wanted to see covsas's stats they would type
for e.g.

"covsassabstats"
and it would come up with
"covsas
total sabbed 2,500,000
50 mithril"

in there would show all the items covsas has sabbed that could include any of the above items in between the ______ lines.

thats should be all the data required if i think of any more ill be sure to post it

Last edited by wozer83; 04/03/07 09:08 PM.
Joined: Feb 2007
Posts: 3
W
wozer83 Offline OP
Self-satisified door
OP Offline
Self-satisified door
W
Joined: Feb 2007
Posts: 3
ermm i guess this cant be done then.

Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
This can be done, however, it is not simple. I noticed a few similarities between your request, and other requests that have been made on the Hawkee forum, so you might want to take a look there.

I suggest that you search the Forums section, as well as the mIRC Snippets section for the keyword SAB


Link Copied to Clipboard