Magine: ok then...today we're going to talk about using the custom
buttons
DLP Anne: ok
Magine: so everyone should have the actions panel selected....
Magine: and as you can see, the buttons are arranged in categories
on different tabs
Magine: the tab marked "." is the miscellaneous category
Magine: you can create new categories just by right-clicking anywhere
on the panel, and choosing "category/add" from the pop-up menu
DLP Anne: eve come
DLP Anne: ok lol dont
Magine: and as you can see on the category pop-up menu, you can
also save a whole category of buttons to a file at once,
Magine: or rename or remove a category.
Magine: is eve not behaving today anne? :D
DLP Anne: she never does lol
Ryan Jacob: lol
Magine: i don't see her
DLP Anne: she is here cause im watching your chat lol
Ryan Jacob: She's in the area I believe
[Eve]: lol
Magine: mags come
[Mags]: Be right there.
Magine: found her? :)
DLP Anne: yup
Magine: ok, so getting back to the buttons....why don't you all
create a new category and name it "class" or whatever you want
DLP Anne: im having to get son ready also so i will catch up
Magine: (to DLP Anne) ok
Ryan Jacob: We can't run out of room with the categories right?
Ryan Jacob: As in, is there a max number of categories?
Magine: not unless your computer runs out of memory, which is unlikely
:)
Magine: right, no max number of categories
Ryan Jacob: ok :)
Magine: oh, i should also mention
Magine: if you don't like the tabs on the bottom,
Magine: you can move them to the top, left or right
Magine: by selection the desired location from the category pop-up
menu (that you get when right clicking)
Magine: by selecting, that is
Ryan Jacob: yeah I see that...pretty neat :)
Magine: you can also copy, cut and paste buttons
Magine: so you can move them from one category to another
Magine: to select a button for copying or cutting, you click on
the button NAME (not the gray button itself)
Magine: and you can hold down ctrl or shift to select buttons
the same as you would select filenames in windows
DLP Anne: i have one question
DLP Anne: how can i get it where its down by my clock minimized
and not in the task bar all the time
Magine: after selecting some buttons, you can right-click and get
a menu to copy, etc them, or use keys like ctrl-insert to copy, shift-insert
to paste, etc
Magine: anne, you can minimize it to the task bar using the window
menu
Magine: on the main menu at the top...
Magine: or else just press ctrl-R
DLP Anne: k
DLP Anne: duh me lol
Magine: which reminds me something i didn't mention last time...
Ryan Jacob: lol I didn't know either Anne
DLP Anne: brb
Magine: you can also drag the magsbot panels into separate windows
Magine: by clicking and dragging on the bar at the top of each
panel
Magine: for instance, try now to click on the bar just above the
buttons and drag the actions panel into it's own window
Magine: you can also size the floating window however you want
Magine: to dock it with the main program again, just drag it back
DLP Anne: cool
Magine: when you have the panels separated into floating windows
like that,
Magine: you can make any of them invisible either by using the
window menu,
Magine: or clicking the appropriate key (listed on the window menu)
Magine: or just click the little x in the upper right of the floating
window
Magine: and you can get the windows back again using the window
menu or the keypresses
Magine: ok, so did everyone create a new category tab earlier?
ZebLith: Yep. :)
DLP Anne: yes
Ryan Jacob: yep I got a category called Class
Magine: ok cool
DLP Anne: got one called ImBlonde :) j/k lol
Magine: when you save categories or buttons individually, the category
is saved in the button file, so when you merge it back in, it goes to the
right category automatically
Magine: :D anne
Magine: you will notice that can also save individual buttons from
the pop-up menu (that you get when you right-click the panel)
Magine: or keys (listed on the popup menu) like F4 to save a button,
etc
Magine: to load saved buttons back in, you use the File menu, under
Action Buttons....
Magine: using "Open Action buttons" to load a whole new set in,
or "Merge Action Buttons" to load in new buttons without removing the current
set
Magine: caution....if you merge a button file that is already there,
Magine: it will create copies of the merged buttons
Magine: it won't overwrite buttons that are there
DLP Anne: cool
Magine: so for instance if you had the "." category already there
and merged it in again
Magine: you would still have one "." category but it would have
2 of each button in it :D
Magine: ok...any questions so far?
Ryan Jacob: none from me :)
ZebLith: Nope. :)
Magine: we will talk about creating buttons next time, but i just
wanted to get you familiar with how they are handled
Magine: today i want to go over how to use the standard buttons
Magine: there are a lot of them, so i won't try to cover them all
in detail, but just the major concepts :)
Magine: and i encourage you to experiment outside of class :)
Magine: if you're not sure what a button does,
Magine: you can peek at the code in the button and look for the
REM statement ( = remark ) that is usually there to explain what it does
Magine: to see the code in a button, you can select the button
and press F2, or you can right click the button and choose "Edit" from
the popup menu
Magine: try that now, if you haven't done so before
Ryan Jacob: I have a question...I don't understand the buttons
that have the brackets [ and ]
Magine: i was just going to come to that :)
Ryan Jacob: lol ok :)
Magine: the buttons with brackets are not meant to be click manually
Magine: they are used by other buttons or by the behavior table
as functions
Magine: which is something we will get to next time when we begin
programming
Magine: so, did everyone take a look at what's inside a button?
Ryan Jacob: yep, but I couldn't make much sense of it
DLP Anne: yes
DLP Anne: chinese
Magine: some of them are very simple, only a line or two, and the
button is just there for convenience
ZebLith: Yeah, can't wait to learn THAT bit. ;)
Magine: and some of them are very complicated
Magine: next week we will start making sense of all that :)
DLP Anne: lol cool i get to learn chinese lol
Magine: heheh
DLP Anne: just kidding lol
Ryan Jacob: lol
Magine: it's actually hungarian notation :D (j/k)
DLP Anne: LOL
Ryan Jacob: lol
ZebLith: hehe :D
Magine: (hungarian notation is a method of naming variables, a
programmer joke)
DLP Anne: oh ok lol
Magine: ok, so anyway...let's play with some of the buttons now...
DLP Anne: ut oh
Magine: let's take a look at the "Movement" category
Magine: many of the things you do with chat commands can also be
done with buttons (more, actually)
Magine: for instance, you can create bookmarks that the bot can
return to
DLP Anne: you mean like a teleport spot we would save?
Magine: yes, exactly
DLP Anne: ok cool very handy
Magine: you can see a "set bookmark from bot" button,
Magine: that creates a bookmark at the bot's current location,
Magine: and also a "set bookmark from target" button,
Magine: which creates a bookmark from the location of some avatar
nearby the bot
Magine: if you have your bot running (and you should! :D)
then click "set bookmark from target" now
DLP Anne: i did cool
Magine: you'll get a pop-up list of nearby avs
Magine: click a name of the list, then type a name for the bookmark
Magine: now you can move the bot to that location (even from another
world) by clicking "goto bookmark"
Magine: and choosing the bookmark name from the list that appears
DLP Anne: coool
DLP Anne: LOL ok
[Mags]: beep
DLP Anne: hi mags
DLP Anne: lol
Ryan Jacob: lol
Magine: you will notice that the bookmark also saves the bot's
avatar
DLP Anne: yes i saw cool
Magine: or the target's avatar
Magine: mags come
[Mags]: Be right there.
Magine: mags av 1
DLP Anne: eve come
DLP Anne: grrrrr lol
Magine: btw you can also use "goto avatar" which works the same
as the "come" command
Magine: eve didn't come to you?
DLP Anne: no she didnt
Magine: are you using the same install as before?
Magine: if not, did you enter your name as a controller?
ZebLith: Ah, how does one do that?
DLP Anne: yeahI am and I did
Magine: that's from last time, zeb....you press F5 and type:
DLP Anne: im checking now i had to change names back
hang one lol
ZebLith: bleh, must have missed it. >_<
Magine: enlist control "ZebLith"
ZebLith: Okay.
Magine: and click ok
DLPAnne: Eve come
DLPAnne: ahhhh that was why
Magine: and that will be saved to a file when you close magsbot
down,
DLPAnne: ee av 1
DLPAnne: lol \eve av 1
Magine: if you have "Files/Variable List/Auto save on close" checked
DLPAnne: *blushing here* lol
Magine: (that should be checked by default)
Magine: what about anne?
DLPAnne: my spelling lol
Magine: oh ok :D ...so, i was saying that you can use
buttons the same as chat commands,
Magine: like "goto avatar" which is like the "come" command
Magine: except you choose the av to goto from a popup list
DLPAnne: ok i see that cool
DLPAnne: hehehe
Magine: "goto avatar position" is similar except the bot will go
to the exact position of the av chosen, instead of standing in front of
them as with the "Goto avatar" button
Magine: "goto avatar position" is the same as the "here" command
Magine: mags here
Magine: and you can see there is also a "follow target" button
Magine: similar to the follow command
Magine: pretty obvious so far, huh? :)
DLPAnne: yup it is
ZebLith: thankfully, lol
Ryan Jacob: lol yep
Magine: now, similar to bookmarks are markers, and positions
Magine: the difference is,
Magine: markers only save the location (not the world and not the
avatar type)
Magine: and positions are pretty much the same as markers except
they are used for something different
Magine: markers are used like bookmarks to move the bot manually
Magine: but positions are numbered instead of named, and are used
for random movement and patrolling
DLPAnne: ahhh ok
ZebLith: Oh, I see.
Magine: markers you set just like bookmarks, using "set marker..."
etc
Magine: positions you set in a similar way, but you should alway
use a number instead of a name when creating a position
Magine: also,
Magine: positions are kept in named lists
Magine: and the lists of positions are used when telling a bot
to patrol or move randomly
DLPAnne: ahhh ok follow ya now cool
Magine: so let's try to set up a random movement list of positions
now, to see just how it works
Magine: move you av to a starting location (in the awb), then click
"set position from target"
Magine: when it asks for a position list to use,
Magine: since we are creating a new list,
Magine: enter some name for it, like "test1" or "class" or whatever
Magine: and enter 1 for the position number
Magine: everyone got that okay?
Ryan Jacob: yep got it
DLPAnne: yep
ZebLith: *nods* Yep
Magine: ok, now move to a few more locations, and at each one,
click "set position from target" again
Magine: you'll use the same list name, but position 2, 3, 4 etc
as you go along
Ryan Jacob: how many should we do?
Magine: 4 or 5 should be ok for this
Ryan Jacob: ok I'm ready
DLPAnne: ok donew
DLPAnne: -w
Magine: ok, once we have the position lists made,
Magine: we can have the bot move from one position to the next
using the "patrol" button
Magine: when asked for the Rate, put in 1000 ( = one second)
DLPAnne: oh miss speedy here LOL
Magine: and of course choose the list you created earlier
Magine: then watch your bot run around between positions :D
DLPAnne: LOL she is on speed i think
Magine: of course you would probably choose a higher number for
the rate, in practical use :D
Magine: when you get tired of watching your frenetic bot :D you
can click "Patrol - Stop"
Ryan Jacob: I pushed Patrol-Stop..I don't see my bot stop lol
Magine: try again
Magine: if that fails, then click "patrol - stop all" instead
Ryan Jacob: I got an error
Magine: oops, what was the error?
Ryan Jacob: [3880368] FreeItem Error, item 3880368 of list
"PA": Variable not foun
Ryan Jacob: [3880368] List "@PA" not found <- for the
patrol - stop all
Magine: hm, it must have already been stopped then
Ryan Jacob: well seems to have stopped now anyways lol
Magine: ok
Magine: which is your bot, ryan?
Magine: version
Ryan Jacob: 4.0 b27
Magine: ok
Magine: it must have already been stopped when you clicked
patrol stop the first time, but still continued moving for a while, delayed
reaction :D
Ryan Jacob: lol..that must be it
DLPAnne: to much sugar in the coffee ryan? lol
Ryan Jacob: lol
Magine: anyway.... :D ....if you would rather have the bot move
randomly between the positions in the list, then you can click "Random
Movement" instead
Magine: with random movement, the bot randomly chooses one of the
positions to go to,
Magine: according to the rate you choose
Magine: the rate = how often the bot might move
DLPAnne: mine is taking forever to move lol
Magine: and the percent change = the chance that it will actually
change position each time it checks
Magine: what rate did you put?
DLPAnne: 50000
Magine: for our test here, 2000 would be better
Magine: try to "random movement - stop"
Magine: and enter 2000 instead
DLPAnne: there she goes
Magine: with 50000 it would only move (maybe) each 50 seconds
Magine: in other words, each 50 seconds the chance of it moving
would be whatever percent you put in when you started it
Magine: (for people reading the log i'll mention that the rate
and percent are entered in pop up menus that appear when you click "random
movement")
DLPAnne: k
DLPAnne: got the hang on it this time
DLPAnne: on = of
Magine: well, there are a lot of other fun buttons, but we are
running out of time here and i'm supposed to talk about variables and lists
today, so you can play with the other buttons on your own :)
DLPAnne: lol ok
Magine: right now i want to talk about surveying and building,
because those buttons use lists a lot
Magine: btw, do you all need to leave at 5pm vrt?
DLPAnne: not me
Magine: we could go to 6pm vrt if everyone wants
(the group decides to proceed until 5pm vrt, then take a half hour break and return)
Magine: so lets talk a bit about surveying now
Magine: you can do a survey several ways
Magine: the simple way is to use the survey dialog
Magine: either press F9 or using the menu, Actions/Survey...
Magine: does the survey dialog seem a little confusing? :D i hope
not, but it has got a lot of options on there
Ryan Jacob: looks very confusing to me lol
Magine: everyone have the survey dialog open?
DLPAnne: a little bit'
DLPAnne: i have the panel yes
Magine: ok, i will go over it all
Magine: the status bar at top, of course shows if a survey is going
on, or an error has occurred, etc
Magine: if you have no bot instances running, it will say "no instances"
Magine: first off you will want to decide if you want a whole-world
survey, or just a local survey
Magine: you can see the "Area" radio buttons on the upper right
of the dialog
DLPAnne: yup
Magine: of course you wouldn't try to do a world survey here in
aw, it would take a month :D and besides we dont have the rights to do
a world survey in a public world
Magine: the two different local survey types only differ in the
area covered
Magine: the 3x3 is a standard survey,
Magine: and the 5x5 is a wider area,
Magine: .
Magine: the survey will by default be performed at the bot's location,
DLPAnne: ok
Magine: but it doesnt have to be. you can enter different location
on the dialog, as you can see.
DLPAnne: right
Magine: as with the bot's location panel, the coordinates are SDK
style,
Magine: but you can enter the familiar AWB coords using the "AW
coords" button
DLPAnne: ok
Magine: the "Relative to origin" checkbox means,
Magine: that the location of the objects in the survey will be
adjusted according to the bot's location
Magine: so when you rebuild from the survey file that is created,
DLPAnne: so that is how a build is moved?
Magine: everything will be moved to GZ
Magine: well let me correct that...it's not relative to the bot's
location, it's relative to the survey location set on the dialog (which
is the same as the bots location only if you don't change it)
Magine: anne, yes, that would be one way to relocate objects
DLPAnne: k
Magine: the "consider altitude" checkbox means the survey will
also be adjusted to the survey location altitude
Magine: for moving things vertically when you rebuild
DLPAnne: so if you save a build at 10 meters up and rebuild without
checking that box it will build it level
Magine: does everyone know what i mean about the "relative to origin"
stuff?
ZebLith: yep :)
DLPAnne: yes
Ryan Jacob: I think I understand it, yes
Magine: well, you don't rebuild from the survey dialog, but essentially
yes anne, that's the idea
Magine: to give an example,
Magine: if you did a survey here with "Relative to origin" checked
Magine: you would get a propdump file (survey file) that would
build everything at GZ
DLPAnne: ohhhh lol that would be a oops
Magine: well i might not be
DLPAnne: unless you want to rebuild a gz lol
Magine: for instance if i wanted to rebuild my gardens here in
a small world
Magine: i wouldn't want to build them at 15n 775e of course
Magine: right :)
Magine: ok, now for the other options....
Magine: "high speed" means that the bot adjusts the way it gets
messages from the world server, to optimize doing a survey
Magine: you would almost always want the "high speed" box checked
DLPAnne: k
Magine: unless you have the bot doing other things at the same
time,
Magine: that you don't want to be interrupted by the survey
Magine: and don't mind the survey taking a long time :)
Magine: you would also leave "propdump format" checked most of
the time
Magine: unless you were searching for only one or two objects and
just wanted to have the info displayed on the bot's chat log instead of
going into a file
Magine: you all know what propdumps are, of course?
Ryan Jacob: I do, yes
DLPAnne: yes
Magine: ok
ZebLith: yeah
Magine: and you would also want "survey to separate log file" checked
most of the time
Magine: otherwise the survey would be shown on the chat log, but
not saved to a file
Magine: "append" means the survey will be added to the end of the
propdump instead of overwriting it, if the file already exists
Magine: and "include tilt,roll" means that the propdump will include
the 3d axis rotation information that is new in version 3.2 or 3.3, whatever
:D of the awb
DLPAnne: k
Magine: (btw if you use my world mapper program i haven't updated
it for the 3d axis stuff so you'd need to use a propdump *without* that
tilt,roll for that)
ZebLith: brb, got some trespassers...
Magine: "save as new default settings" keeps the settings you entered
(but you also need to save configuration, shift-F11 to keep the settings
after you close down magsbot)
DLPAnne: k
Magine: and finally, the most interesting part...the "conditional
expression"
Magine: which begins to get into the magsbot language and programming,
just a bit :)
Magine: which we will get into in detail in the next class, but
Magine: briefly,
Magine: a conditional expression is a mathematical expression (don't
be scared, that just means something like "2+2" or "34*12+6", heheh)
DLPAnne: lol
Ryan Jacob: no calculus I hope ;)
Magine: if the expression equates to anything other than 0,
Magine: (no, no calculus, that scare me too :D)
Magine: if the expression equates to anything other than 0, it
is "true"
Magine: and if it equates to 0 then it is "false"
DLPAnne: well this expression equates confusion lol
Ryan Jacob: LOL
Magine: so....(pop quiz! :D) ...what do you think i
would get in my survey if i put "0" in the conditional expression box?
DLPAnne: false survey
Magine: you would get nothing, right!
DLPAnne: right
Magine: the bot would do the survey but put nothing into the file
Magine: and if you put "1", it would put everything into the file
Magine: (or if you leave the box blank, it assumes "1" and lists
everything)
DLPAnne: so basically you number your surveys?
Magine: no....
DLPAnne: told ya im confused
Magine: you use the conditional expression to filter what objects
go into the propdump
Magine: i was only using "0" and "1" as examples to explain the
concept
DLPAnne: ok
Magine: because normally what you would put in the box,
Magine: would be some meaningful expression that would be "true"
only for the objects you want to survey
Magine: so, if i wanted to survey an area but only for things that
i built myself,
Magine: i could use the expression
Magine: @atr[object_owner]=28777
Magine: 28777 is my citizen number
Ryan Jacob: that's one of the conditions on the list, right?
Magine: and @atr[object_owner] is the citizen number of the person
who created the object
Magine: ryan, that would be *the* condition in the "conditional
expression" box
Magine: we haven't really gotten to the lists yet :)
Ryan Jacob: I had clicked the triangle facing right and then I
clicked Insert Condition
Ryan Jacob: "An object created by a particular person" was there
and I had clicked that lol
Magine: yes, the triangle button there is a help button to show
you the lists of functions you can use in the expression
Magine: that ya go :)
Magine: there ya go, i meant to say
DLPAnne: so you can use this to find tourist builds?
DLPAnne: and delte them
Magine: yes, because all tourists have citizen number 0
DLPAnne: ahhh ok
Magine: so condition @atr[object_owner]=0 would survey only tourist
builds
DLPAnne: ok
Ryan Jacob: what would have to add to that to have the objects
be deleted as the survey finds them?
Magine: another example, if you wanted to only survey a particular
object
Magine: you could do
Magine: @eq[$atr[object_model],$model]]
Magine: but you'd replace $model with the name of the model
Magine: like if you wanted to survey only for tree1m.rwx you could
do
Magine: @eq[$atr[object_model],"tree1m.rwx"]]
Magine: the @eq stuff may be confusing too :)
Magine: you might think that you could do,
Magine: $atr[object_model]="tree1m.rwx"
Magine: but magsbot's language doesn't allow comparing strings
(text) directly like that
Magine: so you need to use a function, the @eq function
DLPAnne: ok
Magine: but once again i'm kind of getting ahead of myself here
Magine: and we're already out of time, unless we want to come back
after a break....
Magine: and i haven't even begun to get to lists, wow
(the group takes the half hour break)
Magine: ok class :) now where were we?
Magine: oh yes, surveying
Ryan Jacob: about to get to lists I think...we were on the conditional
expressions in the survey dialog
Magine: so, we will get into the language in more detail next time,
but do you all get the basic idea of the conditional expression in surveying?
Ryan Jacob: yep
DLPAnne: pretty much yeah
ZebLith: Yeah. :)
Magine: 'k
Magine: now, the last option on the survey dialog,
Magine: is "send to behavior table"
Magine: if you just want to get a propdump file, then uncheck that
Magine: but if you want to make an object list (which i'll start
to explain in a moment),
Magine: then you want to send the survey to the behavior table,
because that is what makes the object list.
Magine: object lists aren't exactly something that is built into
the program
Magine: they are implemented entirely in the behavior table and
buttons
Magine: (although there are a few built-in functions to handle
them)
Magine: to make clear what lists are, i need to talk about variables
Magine: btw, who here has any programming experience at all?
Ryan Jacob: I don't have any programming experience but I do know
what variables are lol :)
ZebLith: Ditto. :)
Magine: ok
Magine: well if you know, forgive me for a quick explanation for
those who might not :)
DLPAnne: ty :)
Magine: in programming terms, a "constant" is a literal reference
to a data type, like 2 or 134.34 or "this is a string"
Magine: and a variable is something that you store data in
Magine: so you refer to it by name
Magine: magsbot has only two kinds of data, numeric or string (text)
Magine: and thus it has two kinds of variables
DLPAnne: ahhh ok
Magine: a numeric variable is a variable in which you store a number,
(duh!) and a string variable stores a string of characters
ZebLith: lol :D
DLPAnne: lol
Ryan Jacob: lol
Magine: numeric variables in magsbot's language have names beginning
with a @
Magine: and string vars have names beginning with $
DLPAnne: ok
ZebLith: oooh
Magine: so @x is a numeric var, $x is a string var
Magine: to store something in a variable ("assign a value") there
are a few different methods in mb's language
Magine: you can use the ASN command ("assign")
Magine: like ASN x=12
Magine: which would create @x and put the value 12 into it
Magine: or, you can use this notation:
Magine: @x=12
Magine: likewise, with string vars,
Magine: you could use
Magine: ASNS x="this is a test"
Magine: or
Magine: $x="this is a test"
Magine: (i hardly ever use the ASN or ASNS anymore, those are old
things left over from early versions of the program, heheh)
Magine: anyway, once you assign something to a var, you can use
the var in it's place
Magine: so instead of a command like
Magine: SAY "how are you today?"
Magine: you could have
Magine: SAY $x
Magine: assuming that $x has "how are you today?" assigned to it.
Magine: all pretty simple, no? :)
DLPAnne: im following so far
ZebLith: Very!
Ryan Jacob: makes sense, yes
Magine: a little more subtle is the concept of local and global
variables
Magine: in programming lingo this is referred to as "scope"
Magine: just FYI :)
Magine: in magsbot, a local variable is a temporary variable,
Magine: that exists only within the particular custom button or
behavior table row that it is created in.
Magine: outside of that button or row, it doesn't exist :)
Magine: and any other button or row won't know anything about it
Magine: but a global variable on the other hand,
Magine: exists until it is destroyed or the program ends
Magine: and is recognized everywhere, by every button and behavior
table row
Magine: does that sort of make sense? I think it will make more
sense next time when we talk about programming more, but you get the general
concept?
DLPAnne: yeah'
ZebLith: Yes, very simple. :)
Ryan Jacob: yep I got it
Magine: ok....anyway, all the lists that magsbot uses are global
in scope
Magine: in fact, lists in magsbot are really just a group of global
variables with similar names
Magine: and before i explain more about that, i need to back up
a bit and explain an unusual feature of variables in mb's language
Magine: in most programming languages (that i've heard of, anyway)
variable names must be constants
Magine: like the examples i gave before
Magine: @x=12
Magine: @foobar=12.476
Magine: @some_big_long_name=3
Magine: $yoho="arrr! matey"
Magine: and so forth
Magine: but in mb's language,
Magine: the variable name can itself be a variable!
Magine: which i suppose is going to be terribly confusing :D
DLPAnne: lol
Magine: but it's also terribly useful i think
Magine: for example,
Magine: instead of just @x=12
Magine: you could have
Magine: $z="x"; ASN $z=12
Magine: (when you use a variable for the variable name like that,
then you *do* need to use the ASN)
DLPAnne: so x=12
Magine: right
DLPAnne: k
Magine: what happens there is,
Magine: the string variable $z gets "x" stored in it
Magine: then the ASN command stores 12 in the variable @x
Magine: brb while you mull that over :D
DLPAnne: lol
Magine: back
DLPAnne: wb
Ryan Jacob: welcome back
Magine: now the reason i'm mentioning this complication
Magine: is because i want to make clear that variables in magsbot
can have unusual names
DLPAnne: ok
Magine: but you need to use the longer ASN command, if the variable
name is unusual
Magine: you can do
Magine: @x=12
Magine: but you can't do
Magine: @hello what do you thing of this weird variable?=18
DLPAnne: lol
Magine: however, you CAN do
Magine: ASN "hello what do you think of this weird variable?"=18
Magine: which creates a numeric variable with a really strange
name and stores 18 in it
Magine: or you could also do this
Magine: $x="hello etc blah blah";
Magine: ASN $x=18
Magine: which would be the same idea
Magine: ok, one more concept here and then lists :)
Magine: the ASN and @x= stuff that i told you,
Magine: is for local (temporary) variables only
Magine: for global variables you can do that same kinds of things,
Magine: but you would use GLOBAL instead of ASN
Magine: and @@x=12 instead of @x=12
Ryan Jacob: @@ global...@ local...correct?
Magine: right
Ryan Jacob: okie dokes
ZebLith: Aaah. :)
Magine: now that double @@ is only used for assignment though.
Magine: for referencing the variable (getting the value back out
of it),
Magine: you still just use the one @
Magine: like
Magine: $$x="hi there!";
Magine: say $x
Ryan Jacob: afk - will brb soon
Magine: that would create a global variable x and put "hi there"
into it,
Magine: so, you might ask, if you see @x, how do you know if it's
a global or local variable?
Magine: well....you don't! :O except in context
Magine: when magsbot sees something like @x
Magine: if a local variable named x exists, then it uses that
Magine: but if no local variable named x exists, but a global variable
named x does exist, then it uses the global
DLPAnne: but it always searches for the local first right
Magine: correct! :)
DLPAnne: gotcha
Magine: ok, so now i can explain lists in more detail
Magine: you back yet ryan?
Magine: well....anyway....
Magine: as i said before, lists in magsbot as just groups of global
variables with similar names
Magine: so for instance if you have a string list named "foobar"
Magine: then what it really is,
Magine: is a group of global string variables named
Magine: $foobar:1
Magine: $foobar:2
Magine: $foobar:3
Magine: and so forth
Magine: time for a visual aid :)
DLPAnne: k
Magine: press ctrl-F3 in magsbot
Magine: that's the global variable list you see
Magine: you can see the bookmarks you created
DLPAnne: yup
DLPAnne: $RM-1:6
Magine: and the $RM_ variables are the position lists
DLPAnne: up
DLPAnne: er yeah lol
Magine: (RM=random movement)
Magine: you can also see $control:1 and your name
DLPAnne: lol I have 3 of those
Magine: lol then you must have done ENLIST control DLPAnne three
times
DLPAnne: prolly
Magine: you can delete the last 2 if you want :D
Magine: just select them and click Delete on the menu
Magine: extra ones won't make the bot more obedient, alas :D
Magine: so you can sort of see what i mean about lists being groups
of similarly names variables, yes?
DLP Anne: yes
Magine: now....getting back to surveying....
ZebLith: ^^
Magine: everything make some sense, zeb? :)
ZebLith: of course. :)
Magine: let's look at the "survey" category of the buttons for
a moment
Magine: there are a lot of buttons there for creating object lists
from survey
Magine: they are an alternative to using the survey dialog we looked
at before
Magine: and when you do a survey using these buttons, it creates
an object list
Magine: let's try it and you'll see what i mean....first,
Magine: click "log from survey",
Magine: and when asked for conditions, just enter 1
Magine: and choose "Yes" when it asks about overwriting the current
ObjLog
DLP Anne: mine just went crazy lol
Magine: since we don't want this to take forever, you can stop
the survey by opening the survey dialog (F9) and click Stop
ZebLith: ditto XD
DLP Anne: whew she was sweating lready LOL
Magine: heheh
ZebLith: sheesh, still adding. O_O
Magine: ok, the survey should stop after a second, but you will
see at the bottom of the magsbot window,
DLP Anne: lol
Magine: the monitor bar (where it says Events and Actions),
Magine: will have the Event bar completely full for a while
Magine: you all have the monitor bar showing, right?
ZebLith: yeah.
Magine: if not, press Ctrl-M to open it
Magine: ok
Magine: the Events bar there shows event messages that magsbot
has received from the world server, in this case they are mostly all CELLOBJECT
messages that are sent by a survey
Magine: and the reason it takes some time for the bar to clear,
Magine: is because each of those messages is being processed by
the behavior table
Magine: the behavior table has code in it that creates the object
list
Magine: in this case the object list is named $ObjLog
Magine: open your variable list window again (Ctrl-F3)
DLP Anne: wow
Magine: and now you can see the objlect list in there
Magine: (oh btw, generally you don't want to leave the var list
window open when the bot is really busy because it slows things down tremendously)
Magine: as you can see, the object list is really just a group
of global variables
Magine: with names like
Magine: $ObjLog:110620703 etc
Magine: and each list item contains a string with info from the
survey
Ryan Jacob: back, I read through and got caught up
ZebLith: welcome back. :)
DLP Anne: wb:
Magine: re hi :)
DLP Anne: )
Magine: i should comment that not all lists in magsbot are object
lists.....
Magine: "object list" refers specifically to lists created from
surveys
Magine: in the case of object lists, the item numbers (those numbers
to the right of the : in the name) are the AW object numbers
Magine: the information in each variable is like the info you get
in a propdump
Magine: and the object numbers are what you use when changing or
deleting the objects
Magine: does that make sense? any confusion here? :)
Ryan Jacob: everything looks good to me
ZebLith: yes, no. makes sense. :)
DLP Anne: still following along
Magine: ok
Magine: well now that you have the object list, you can manipulate
it in any number of ways, using buttons in the Lists or Build categories
Magine: if you click "Object Log" button in the Lists category,
you will see ObjLog there, as in the var list window
DLP Anne: wow eve was fast lol
Magine: you can save the object list to a file, either in the obj
list format using "save obj list to file" or in propdump format using "save
obj list as propdump"
Magine: in either case you'd put ObjLog for the name of the list
and whatever file name you choose
Magine: however there is a bit of a bug, when you save an obj list
as a propdump, it will only work if "Options/Include Tilt-Roll" is checked
DLP Anne: question
DLP Anne: if it saves to file it has a .txt ext right
DLP Anne: and can it be used by the world server to reload a world?
Magine: the world server can only use propdump files [like those
made by magsbot using the survey dialog]
DLP Anne: ok
Magine: but magsbot can load either propdump files or object list
format files
DLP Anne: so saving to propdump will allow to reload thru the server
then
[Magine: yes, magsbot propdumps are just like the ones the world
server uses]
Magine: if you want to build a propdump using magsbot, the fastest
way is to just use the "build from propdump" button in the build category
DLP Anne: kk
Magine: but you could also load in an object list file [using "read
obj list from file"], play with it in various ways, then build it using
"build from obj list" in the build category
DLP Anne: can she change cit numbers in a prop dump?
Magine: yes [when using an obj list] there is a search and replace
button [used to change objects in an obj list as it rebuilds]
DLP Anne: kk
Magine: the main advantage of obj list files over propdumps is,
Magine: that you can't edit the model, description or action fields
in a propdump
Magine: but you can edit obj list files
Magine: with a text editor that is
DLP Anne: coool
Magine: then load them back in and rebuild
Magine: also propdumps don't store object numbers,
Magine: so you can't use them to *change* or delete objects [only
to build]
[Magine: but obj lists can be used to change or delete as well
as build]
Magine: any questions before we wrap up for this session?
DLP Anne: nope
Ryan Jacob: I have a question
Magine: yes ryan?
Ryan Jacob: in the conditional expressions box for a survey, can
I have the bot do anything to the objects automatically?
Ryan Jacob: change owner, delete objects, etc.?
Magine: well, you could write something in the behavior table that
could do that,
Magine: but not using the survey dialog, no
Magine: the conditional expression for surveying is only a filter
that detemines what objects get surveyed
Ryan Jacob: okay..but if I could write a command in the behavior
table that..for instance, I said the command "clean" would go through and
delete all tourist objects in a world?
Magine: yes
Ryan Jacob: ok, and that'll be coming up later..ok thanks :)
Magine: you could write something like that, sure
Magine: yep we can talk about that when we get to the behavior
table stuff....
Magine: remind me :)
Ryan Jacob: alrighty :)
DLP Anne: yeah that would be good for me to have as well
Magine: anything else? last call :)
DLP Anne: nope
ZebLith: don't think so. :)
Ryan Jacob: I think you covered everything pretty well
Magine: actually you could do that tourist delete thing now, just
in two steps
Magine: first "log from survey" with condition @atr[object_owner]=0
then after the survey is complete, do "delete from obj list"
Magine: but you could write a behavior table routine that would
delete as the survey takes place, as you said, yeah
Magine: which would be faster, good idea :)
Magine: alrighty then, hope to see you all next time :)
Ryan Jacob: alrighty..thank you so much :)
ZebLith: ^^ Thanks Magine!
DLP Anne: lol will be here if I dont get sidetracked again
Magine: you are very welcome :)
DLP Anne: Thanks Magine :)
Magine: bye all, have fun and experiment :)
DLP Anne: byeee pooof