3/24/2023 0 Comments Mudlet prompt return![]() ![]() When playing an IRE game, a call to send(" ") afterwards is necessary due to a bug in the game with compression (MCCP) is enabled. A call to sendGMCP would not be required in this case. For example, LOOKing in your room prompts the server to send the room description and contents, as well as the GMCP message gmcp.Room. ![]() For most GMCP modules, the messages are automatically sent by the server when a relevant event happens in the game. Note that this function is rarely used in practice. The IRE document on GMCP has information about what can be sent, and what tables it will use, etcetera. Need example sendGMCP sendGMCP(command) Sends a GMCP message to the server. instead of using many send() calls, you can use one sendAll sendAll ( "outr paint", "outr canvas", "paint canvas" ) - can also have the commands not be echoed sendAll ( "hi", "bye", false ) sendATCP sendATCP(message, what) Need description See also: ATCP Protocol, ATCP Extensions, Achaea Telnet Client Protocol specification, Description by forum user KaVir (2013), Description by forum user Iocun (2009) Parameters GetConnectionInfo getConnectionInfo() Returns the server address and port that you're currently connected to, and (in Mudlet 4.12+) true or false indicating if you're currently connected to a game. " players on right now." ) end - register our function to run on the event that something was downloaded registerAnonymousEventHandler ( "sysDownloadDone", "downloaded_file" ) - download a list of fake users for a demo downloadFile ( getMudletHomeDir (). create a function to parse the downloaded webpage and display a result function downloaded_file ( _, filename ) - is the file that downloaded ours? if not filename : find ( "achaea-who-count.html", 1, true ) then return end - read the contents of the webpage in local f, s, webpage = io.open ( filename ) if f then webpage = f : read ( "*a" ) io.close ( f ) end - delete the file on disk, don't clutter os.remove ( filename ) - parse our downloaded file for the player count local pc = webpage : match ( ] ) display ( "Achaea has ". ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |