A text Myst Online project
Re: A text Myst Online project
Huzzah! Thank you Belford!
Have Ages, and link to them without bindings. [Words 1:13]
Seltani
Seltani
-
- Posts: 79
- Joined: Mon Jun 10, 2013 2:29 am
Re: A text Myst Online project
I'll be back in England in 17 hours or so. Then I can build my AIs!
Moula KI: 17967159
DI KI: 00205116
deviantART: kathaveara
tumblr: kaththedragon
Grand Master of the Guild of Linguists
DI KI: 00205116
deviantART: kathaveara
tumblr: kaththedragon
Grand Master of the Guild of Linguists
Re: A text Myst Online project
What's the reasoning behind players.player(foo) and players.name(foo)? The distinction seems subtle and confusing, and I don't see the value of having the distinction.
Have Ages, and link to them without bindings. [Words 1:13]
Seltani
Seltani
Re: A text Myst Online project
You can now add linking books to the shelves in your personal Tsani-Tsina instance.
Have Ages, and link to them without bindings. [Words 1:13]
Seltani
Seltani
Re: A text Myst Online project
The first is a player object, and the second is a string. They're not interchangeable. Use a player object to get a player properties, and to pass to other players.xxx() functions. The player name is only for printing.What's the reasoning behind players.player(foo) and players.name(foo)?
Re: A text Myst Online project
You can now set the focus to a code property, although it's not automatic. It would look like:
...where sign is a code property that calls print() to generate output.
The behavior of print() is not yet as general as I'd like, but it works for this case.
Other changes today:
The unfocus() function is documented.
Invoking a code property can be done either with or without parentheses. That is, the following are equivalent:
(You cannot yet pass arguments to a code property, but I'll get there.)
http://seltani.net/doc/ now refers to the wiki. The wiki is the primary documentation at this point.
I've added a section on books and bookshelves to the wiki. (http://seltani.shoutwiki.com/wiki/Writi ... _bookshelf)
In the build interface, when you enter a text or code property, the syntax is validated before it's saved.
In the build interface, the "create portal to this location" now creates a global link rather than a personal link. (Unless the world is marked solo, of course.)
Code: Select all
setfocus("sign")
The behavior of print() is not yet as general as I'd like, but it works for this case.
Other changes today:
The unfocus() function is documented.
Invoking a code property can be done either with or without parentheses. That is, the following are equivalent:
Code: Select all
dosomething
dosomething()
http://seltani.net/doc/ now refers to the wiki. The wiki is the primary documentation at this point.
I've added a section on books and bookshelves to the wiki. (http://seltani.shoutwiki.com/wiki/Writi ... _bookshelf)
In the build interface, when you enter a text or code property, the syntax is validated before it's saved.
In the build interface, the "create portal to this location" now creates a global link rather than a personal link. (Unless the world is marked solo, of course.)
Re: A text Myst Online project
belford wrote:The first is a player object, and the second is a string. They're not interchangeable. Use a player object to get a player properties, and to pass to other players.xxx() functions. The player name is only for printing.What's the reasoning behind players.player(foo) and players.name(foo)?
Should this read "Returns the player object of the acting player[...]"?the wiki wrote:players.player()
players.player(player)
Returns the name of the acting player, or the player with the given database key (an ObjectId). If the argument is a player object, this returns it unchanged.
Have Ages, and link to them without bindings. [Words 1:13]
Seltani
Seltani
Re: A text Myst Online project
Yes, right. Thanks.
Could you set me to have main-page editing access on the wiki?
Could you set me to have main-page editing access on the wiki?
Re: A text Myst Online project
Done, I think. I don't know of a way for me to test whether I did it correctly.
Have Ages, and link to them without bindings. [Words 1:13]
Seltani
Seltani
-
- Posts: 79
- Joined: Mon Jun 10, 2013 2:29 am
Re: A text Myst Online project
Hey, Belford, could we have for loops enabled, please? I have some code (below) as part of my snake AI that could really do with a for loop.
The current code is:
and with a for loop, I could reduce it to one-quarter the size.
The current code is:
Code: Select all
if snakepos == 1:
if foodpos % 2 < 1:
foodpos -= 1
snakehunger += 3
elif snakepos == 2:
if foodpos % 4 < 2:
foodpos -= 2
snakehunger += 3
elif snakepos == 3:
if foodpos % 8 < 4:
foodpos -= 4
snakehunger += 3
elif snakepos == 4:
if foodpos < 8:
foodpos -= 8
snakehunger += 3
Moula KI: 17967159
DI KI: 00205116
deviantART: kathaveara
tumblr: kaththedragon
Grand Master of the Guild of Linguists
DI KI: 00205116
deviantART: kathaveara
tumblr: kaththedragon
Grand Master of the Guild of Linguists