|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Sun Apr 10, 2005 3:37 pm
How to input a huge list into a Zmud variable |
two part question. im trying to input 3 lists. 1 for mobs. 1 for thier level, another for the area they are in.
there are about 600 mobs for each letter of the alphabet A to Z
I can list the mobs and get the list in column form in excel. my question is how do i get zmud them to zmud in variable form with a cut and paste. im trying to figure out how to do it and excel can't handle such a long list pasted from column to row.
Second question is can zmud handle a variable this size. I would like to break it down into each letter so i might be able to update it.
all i know is zmud only seems to like when things are pasted like
Mobname|mobother|etc|etc
but i have huge lists of columns and i can't figure out how to get it into zmud without spending hours changing it. i tought of using replace to replace each space with | but the mobs names have more then one name sometimes and spaces in them. Here's an example of the list
abomination 34 Land of Dominia
abyss monster 27 Castle Reinhold
Achenar 185 MYST
only i can get it columned if i want for just mobname level area.
Any help would be thx
P.S what the finish product is- on campaigns you sometimes only get mob names and the room they are in, not the area. i want to make a script to automaticly tell me the area its in, if its without +- 30 levels of me. dunno how im gonna do it but im told zmud can do anything
Gurn |
|
|
|
Private Adept
Joined: 10 Jan 2002 Posts: 264 Location: USA
|
Posted: Mon Apr 11, 2005 7:04 am |
What i did for campaigns/gquests/quests is make a mob database, and then set MXP triggers for like:
Pattern: You still have to kill (%d) ~* (*) ~((*)~)
Value: #SUB {Kill %1 ~* %ansi(red)<send 'mobfind "%2"'>%2</send> %ansi(grey)~(%ansi(green)<send 'mapfind "%3"'>%3</send>%ansi(grey)~) %3}
then what i see is clickable links to my mobfind and roomfind aliases, and my mapfind will also ouput to #SAY the room im looking for in case its a area instead of room, I have Areanames MXP subbed as well to click-walk to the area.
My first mob database was aquired from a LONG uptime and a script i wrote to execute:
mobdeaths 1 1 good
mobdeaths 1 1 evil
mobdeaths 2 2 good
mobdeaths 2 2 evil
etc to 240 and captured the level, mob, area, align to a text file...i pulled that text file into UltraEdit(text editor) and formatted it "level"TAB"mobname"TAB"area_name"TAB"alignment"
then just imported it into a zmud database.
ran the "mobdeaths 1 1" etc script again without specifying good/evil and any mobs not found in database already were assumed to be neutral align :)
When i click on a mobname from campaign/gquest check, the mobfind alias would #show all matching records, only spammed me slightly for some mobs... like "a rat" ---
5279 Name: 'A rat' Lvl: 12 Area: War of the Wizards Align: neutral Speedwalk: 14654 yet Room: On the battlefield Notes: none
1475 Name: 'A rat' Lvl: 90 Area: Northstar Align: evil Speedwalk: 2904 Room: The Front of The Temple Notes: or Speedwalk: 2877 - Bad Part of Town
1473 Name: 'A rat' Lvl: 156 Area: Mossflower Wood Align: evil Speedwalk: 12220 Room: A Meadow Notes: none |
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Mon Apr 11, 2005 2:44 pm |
wow thats much better then i was thinking of doing it. Im not familiar with #sub command or menu's besides a simple menu you can right click on a players name and spell him up.
one thing i have going. i have the data already collected. going to try ultraedit cuss i can't find an easy way to input it all into zmud. Another thing i realize. i can't update my list so i will have to do something like what you did to mobdeath 1 1 good .. etc. thats good idea to capture to txt. did you just save the log? or is there a command to send only some items to txt.
How did you gather the room name data? or are you adding that with campaigns?
My plan was to have 3 variables. mobname level area. if the area isn't in my area list then it must be a room name and the script will somehow output what area its in. the output i havn't figured out how to do best. doing it this way is kinda here and there cuss if on of the lists gets messed at all then it wont align right with the other two for count in list compared to the other lists. plus it would be messy to update. i like your way.
It's going to take me a long time to figure that out. plus i use paths to get around for sw's. your number system seems real custom obviously :)
Thanks
Gurn |
|
|
|
Private Adept
Joined: 10 Jan 2002 Posts: 264 Location: USA
|
Posted: Mon Apr 11, 2005 3:25 pm |
2 triggers to capture, i turn the class on/off manually when i wanna do it...
#TRIGGER {(%s)(%d) - (*)(%s)(%d) (%*)(%s)(%d)$} {#FILE 4 mobs.txt;#WRI 4 {%trimright( %3)-,-%5-,-%6-,-@align}}
#TRIGGER {-------------------------------~[ THE END ~]--------------------------} {#CLOSE 4}
enter those triggers and type
align = good
mobdeaths 1 1 good
align = evil
mobdeaths 1 1 evil
you will have a text file in your zmud directory titled mobs.txt, if the mud was up for several weeks, it will contain most quest/gquest/leveling mobs for level 1 of good and evil varieties in comma seperated format... open it in your favorite editor, and replace -,- with a tab (^t in ultraedit), pretty easy to import into a zmud database after that... the reason on the -,- is to easily be able to seperate the ,'s from commas in mob/area names... i.e. Rokugan, The Shadowlands (as a side not... you will want do do some other search and replaces, areas like "The Onslaught of Chaos" gets truncated to "The Onslaught of Cha" in mobdeaths... also some mob names get truncated... "An obnoxiously cheerful k" = "an obnoxiously cheerful kender", not much you can do about that, i manually edit as i come across them.
This method was what i used as a help to room_name campaigns, since then ive scrapped it and went to each area and added all mobs room by room, but there are some like in Wyrm that i aint big enough for yet, so i added those from the old database :)
as i do campaigns/quests/gquests (i log all that info) i go back and manually add roomname and speedwalks from the mapper.
To add neutral mobs from mobdeaths is a lot more complicated, youll need to get all the good/evil mobs you want in it 1st, then that 1st trigger can be modified to look up a mob before it adds it, if its in the database, it is good or evil, if not, assume neutral (of course mobs that made it into mobdeaths in between might be in error as to align)
The #'s i use for speedwalks are the map 'ObjID' from the mapper, as you can #WALK ObjID# |
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Mon Apr 11, 2005 5:25 pm |
another thing. how did you use ultraedit on the txt logs of mobdeath info.
i have a trial version of ultraedit, fully functional for 30 days so anyways. just wondering how you set it up
you wrote
UltraEdit(text editor) and formatted it "level"TAB"mobname"TAB"area_name"TAB"alignment"
then just imported it into a zmud database.
i just didn't understand the tab part? do i not need it in |mobname|mobtwo|mobthree etc.. in order for zmud to take it?
Im thinking use #cap to seperate the results into 2 windows. good and evil. then just save the logs for those to windows. how you changed it "easily" so it would be ready to input into zmud is what im asking. just to be clear
Gurn |
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Mon Apr 11, 2005 5:28 pm |
ignore last msg .. didn't see your reply
|
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Mon Apr 11, 2005 5:40 pm |
wow thats awesome. im familiar with ifmember commands. i assume thats what your using to look up mobs with your mobfind. can you show me what your alias mobfind looks like. reason is i just was wondering if you also knew a better way to find and show the info. as for the mapper stuff, i dont use a mapper so you dont have to explain all that stuff.
so just wondering how you handled the variables. it looks like you might have imported them each with there own number? or is that part of your mapper. anyways how would you suggest i organize them?
Thanks a ton btw this is great. saved me basicly giving up on the whole thing cuss i couldn't think of a way to do it all.
Gurn |
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Tue Apr 12, 2005 1:03 am how does your alias mobfind work |
can you show me how your mobfind alias works and how your pulling the info from database? did you store everythign in one huge varable for align,level,mob,area?
i looked up everything else i dont think zmud 6.16 uses send the same way but i figured it out and modded it. just wondering the contents of your findmob alias
thx |
|
|
|
Private Adept
Joined: 10 Jan 2002 Posts: 264 Location: USA
|
Posted: Tue Apr 12, 2005 7:15 am |
after i get all the good and evil mobs and they are in the database, i alter the capture trigger commands to do...
#TRIGGER {(%s)(%d) - (*)(%s)(%d) (%*)(%s)(%d)$} {data = {%find( '%3', all);numitems = "";@numitems = %numitems( @data);#IF (%numitems( @data) = 0) {#FILE 4 mobs.txt;#WRI 4 {%trimright( %3)-,-%5-,-%6-,-neutral}} {#show Mob exits in database}}
#TRIGGER {-------------------------------~[ THE END ~]--------------------------} {#CLOSE 4}
what that does is lookup the mobname and if it isn't in the database, it now adds it as neutral...
you could do that from the start, but mobs that load (like guards in DSP) with an evil and a neutral one wouldnt be added but once as either evil or good but not their counterpart. |
|
|
|
GURNGURN Newbie
Joined: 05 Apr 2005 Posts: 9
|
Posted: Tue Apr 12, 2005 1:25 pm |
ok thanks. I was wondering how you are outputing the data when its all done. everything up till that i understand. how do you get it to say the data
5279 Name: 'A rat' Lvl: 12 Area: War of the Wizards Align: neutral Speedwalk: 14654 yet Room: On the battlefield Notes: none
1475 Name: 'A rat' Lvl: 90 Area: Northstar Align: evil Speedwalk: 2904 Room: The Front of The Temple Notes: or Speedwalk: 2877 - Bad Part of Town
1473 Name: 'A rat' Lvl: 156 Area: Mossflower Wood Align: evil Speedwalk: 12220 Room: A Meadow Notes: none
minus the sw #'s, cuss i dont have that anyways, and room i dont need.
I was thinking of having it only show mobs that are +-30 levels of my current level. maybe less spam that way. if you could show me how that alias mobfind pulls the data from the database i should be fine from there. I spent a couple hours last night learning about MXP and databases, still learning database though. i've gotten to the point i can import the data.
I can't figure out the easy part. retrieving the data and showing it for
'A Rat' '156' 'mossflower wood'
and maybe after i figure that much out. only showing the mobs that are +-30 levels of me.
My goal at the start was to sub out room names only in campaign info and sub in the area name. so the script would be invisable. one day i'll get it that far. |
|
|
|
Private Adept
Joined: 10 Jan 2002 Posts: 264 Location: USA
|
Posted: Tue Apr 12, 2005 6:22 pm |
There is prolly a lot of stuff in this alias that is useless... but i was to lazy to re-write it from another mud i used it on.... so i only changed what i needed to make it work :P
#ALIAS mobfind {#DBLOAD mo
#DBRESET
data = ""
#IF !%null( %2) {current_zone = %1}
#IF %null( %2) {
data = {%find( '%1', all)}
#find '%1' all
} {
data = {%find( ,%2)}
#find '' %2
}
numitems = ""
@numitems = %numitems( @data)
#IF (%numitems( @data) = 0) {
#IF (%1 = "") {} {
#show {}
#show %ansi( high, white) Not found in database or bad spelling
} {}
} {
#IF (%numitems( @data) > 25) {
#show {}
#SHOW %ansi( high, white) Found @numitems objects, limit is 25
} {
#IF %null( %1) {
#show {}
#show %ansi( high, white) Please give me a keyword
} {
#show {}
#show %ansi( white) OzzyMobDB v@mob_version - Found @numitems matches - %replace( %replace( @data, "mo", " "), "|", " | ")
#FORALL @data {
#show {}
#SAY %ansi( high, white) %replace( %replace( %replace( %replace( %replace( %replace( %replace( %replace( %stripansi( %dbget( %i)), mob_level, "' Lvl: "), mob_name, " Name: '"), mob_zone, " Area: "), mob_align, " Align: "), mob_speedwalk, " Speedwalk: "), mob_roomname, " Room: "), "mo ", " "), Notes, " Notes: ")
}
}
}
}
#SHOW {}
#SAY %ansi( white) OzzyMobDB v@mob_version - Found @numitems matches %replace( %replace( @data, "mo", ""), "|", " | ")
#SHOW {}
#SHOW %ansi( white)@numitems matches.}
the %replace's are how i format it. |
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|