* various bug fixes detailed on *clp
* unstable containment artifact added
* medical bay artifact added
* shrike spear artifact added, and weapon/attack
Wayfar 1444 is a text based online multiplayer game. You are a colonist, sent to the surface of an alien world with a few basic supplies. Join up with other colonists, or plot against them, while surviving and building a self sufficient colony.
Wednesday, April 25, 2012
Saturday, April 21, 2012
LambdaMOO/Hellcore: Broadcasting to an IRC server
On Wayfar, when a player is killed they get a death taunt in the style of the LORD or BBS door games. When enough kills are accumulated the MOO connects to an IRC server, posts a kill update, and then disconnects.
The commands to interact with an IRC server are straightforward:
conn = open_network_connection(server, port);
set_connection_option(conn, "hold-input", 1);
Open the connection and tell the MOO not interpret anything on this connection as a game command.
notify(conn, "USER YOUR_USR_NAME 8 * : your_comment");
botname = "Jerkturkey";
notify(conn, "NICK " + botname);
That sends the USER and NICK. Now the IRC server will send a bunch of nonsense at you, then disconnect you if you don't answer the ping request in time. So we wait for the first ping before we start sending messages:
while (line = read(conn))
if (hurf = $su:explode(line))
if ($su:uppercase(hurf[1]) == "PING")
notify(conn, "PONG " + hurf[2]);
break;
endif
endif
endwhile
Note that we have to reply with information from the request. Next up, join a channel:
notify(conn, "JOIN #wayfar1444");
Send whatever messages we've arranged, preferably a batch of messages:
for x in ($web.irc_queue)
notify(conn, "PRIVMSG #wayfar1444 :"+x);
endfor
Tell the IRC server we're leaving and disconnect:
notify(conn, "QUIT");
boot_player(conn);
The commands to interact with an IRC server are straightforward:
conn = open_network_connection(server, port);
set_connection_option(conn, "hold-input", 1);
Open the connection and tell the MOO not interpret anything on this connection as a game command.
notify(conn, "USER YOUR_USR_NAME 8 * : your_comment");
botname = "Jerkturkey";
notify(conn, "NICK " + botname);
That sends the USER and NICK. Now the IRC server will send a bunch of nonsense at you, then disconnect you if you don't answer the ping request in time. So we wait for the first ping before we start sending messages:
while (line = read(conn))
if (hurf = $su:explode(line))
if ($su:uppercase(hurf[1]) == "PING")
notify(conn, "PONG " + hurf[2]);
break;
endif
endif
endwhile
Note that we have to reply with information from the request. Next up, join a channel:
notify(conn, "JOIN #wayfar1444");
Send whatever messages we've arranged, preferably a batch of messages:
for x in ($web.irc_queue)
notify(conn, "PRIVMSG #wayfar1444 :"+x);
endfor
Tell the IRC server we're leaving and disconnect:
notify(conn, "QUIT");
boot_player(conn);
Friday, April 20, 2012
Updates 4/20/12
* reroll storage locker for saving player gear between ascensions
* increased the consider output for products, weapons, armor
* added a repossession AI - instead of player vehicles and buildings being destroyed they will become purchaseable and hackable
* bug fixesss
* added player nicknames and nicknames unlocked by skill acquisition
* Data Pro no longer requires the off-world operation skill Data Operation.
* minor cleanups to the skills interface
* improved the starship landing interface with more information
* NPC equipping routines cleaned up
* couple of wildlife and products added
* added an advanced version of the basic tool that will prompt for materials instead of requiring manual addition:
* massive upgrade to the holo-vid generator, courtesy of Cheechlizard:
* increased the consider output for products, weapons, armor
* added a repossession AI - instead of player vehicles and buildings being destroyed they will become purchaseable and hackable
* bug fixesss
* added player nicknames and nicknames unlocked by skill acquisition
* Data Pro no longer requires the off-world operation skill Data Operation.
* minor cleanups to the skills interface
* improved the starship landing interface with more information
* NPC equipping routines cleaned up
* couple of wildlife and products added
* added an advanced version of the basic tool that will prompt for materials instead of requiring manual addition:
* massive upgrade to the holo-vid generator, courtesy of Cheechlizard:
Tuesday, April 17, 2012
How to write a useable item in Hellcore/Wayfar
Step 1: create the item from an appropriate parent.
Step 2: add a verb on the item for the player to kick off the action, it should look like this:
@verb #itemid:use this none none
1: if(this.location != player)
2: return player:tell("You have to be holding this to use it!");
3: else
4: player:queue_action($actions.use, {this, #-1}, 1, "use "+this:name());
5: endif
Step 3: Write two new verbs on the item to handle the use action:
do_use_start(OBJ who, OBJ on)
do_use_finish(OBJ who, OBJ on)
In our example we are just using the item, we aren't using it on anything. This would need a more complex verb on the item in the form of:
@verb #itemid use this on any
And then you'd need to match the any against and item or person.
Step 2: add a verb on the item for the player to kick off the action, it should look like this:
@verb #itemid:use this none none
1: if(this.location != player)
2: return player:tell("You have to be holding this to use it!");
3: else
4: player:queue_action($actions.use, {this, #-1}, 1, "use "+this:name());
5: endif
Step 3: Write two new verbs on the item to handle the use action:
do_use_start(OBJ who, OBJ on)
do_use_finish(OBJ who, OBJ on)
In our example we are just using the item, we aren't using it on anything. This would need a more complex verb on the item in the form of:
@verb #itemid use this on any
And then you'd need to match the any against and item or person.
Updates 4/17/12
* added the first working artifact, a faulty auspex that scans for hidden items nearby. It can be researched from a discoverable green orb found in forest biomes.
* TV and camera system implemented by Tigwyk:
* a multitude of bug fixes
* TV and camera system implemented by Tigwyk:
* a multitude of bug fixes
Subscribe to:
Posts (Atom)


