Advanced Functions.
[API Functions]

Advanced functions that depend on code and memory hacks. More...

Functions

F2LINK void F2CALL f2__setplayerinfo (const char *name, const char *pw, const char *color, const char *desc, const unsigned int *guid)
 Sets internal player information.
F2LINK void F2CALL f2__setmainsocket (SOCKET socket)
 Replaces the client's main connection socket handle.
F2LINK void F2CALL f2__pushchatbox (const char *line)
 Pushes a line of text into the chat buffer.
F2LINK bool F2CALL f2__ignore_add (const char *name)
 Adds an ignore.
F2LINK bool F2CALL f2__ignore_rm (const char *name)
 Removes an ignore.
F2LINK bool F2CALL f2__ignore_test (const char *name)
 Tests if a name is ignored.
F2LINK const char *F2CALL f2__playermenu_name ()
 Retrieves the player shortname associated with the last player menu popup.

Detailed Description

Advanced functions that depend on code and memory hacks.

With these methods, you can manipulate aspects the client and its behavior. Be warned; because these require intimate interaction with the client, they are guaranteed to cease working if a new client build is released or memlocs don't match up. To test for this condition, see f2_buildok().


Function Documentation

F2LINK bool F2CALL furn2::f2__ignore_add ( const char *  name  ) 

Adds an ignore.

Parameters:
[in] name Name to ignore. If name starts with a '@', indicates a channel.
Returns:
true if successful.

F2LINK bool F2CALL furn2::f2__ignore_rm ( const char *  name  ) 

Removes an ignore.

Parameters:
[in] name Name to unignore. If name starts with a '@', indicates a channel.
Returns:
true if successful.

F2LINK bool F2CALL furn2::f2__ignore_test ( const char *  name  ) 

Tests if a name is ignored.

Parameters:
[in] name Name to test. If name starts with a '@', indicates a channel.
Returns:
true if ignored.

F2LINK const char* F2CALL furn2::f2__playermenu_name (  ) 

Retrieves the player shortname associated with the last player menu popup.

Returns:
A shortname.
Remarks:
The lifetime of the buffer returned by this function is indefinite, thus the string should be copied immediately if you intend to reference it at a later time.
See also:
Menu Functions.

F2LINK void F2CALL furn2::f2__pushchatbox ( const char *  line  ) 

Pushes a line of text into the chat buffer.

Parameters:
[in] line The line of text.
Remarks:
This should always work, regardless of the client build, in some way.

F2LINK void F2CALL furn2::f2__setmainsocket ( SOCKET  socket  ) 

Replaces the client's main connection socket handle.

Parameters:
[in] socket Replacement socket handle.
Remarks:
The old socket will be restored to blocking IO mode, but not shutdown or closed. Be sure to properly deallocate the old socket yourself.

The new socket will be immediately WSAAsyncSelected into asynchronous mode for the client, and an FD_READ event will be posted to the message queue.
Warning:
Care must be taken to make sure the sockets are in the same connection level. That is, they're both waiting for the MOTD text to arrive, have received the MOTD text, or are logged in. Replacing the current socket with one in a different connection level could have strange results.

F2LINK void F2CALL furn2::f2__setplayerinfo ( const char *  name,
const char *  pw,
const char *  color,
const char *  desc,
const unsigned int *  guid 
)

Sets internal player information.

Parameters:
[in] name Player name (optional if NULL).
[in] pw Player password (optional if NULL).
[in] color Player (complete, 13 byte) color code (optional if NULL).
[in] desc Player description (optional if NULL).
[in] guid Player GUID (optional if NULL).
Remarks:
When the client changes maps, the client restores the portrait area to show the current player, based on these values. The name and password may also be used in opening fileserver connections.

Passing a parameter as NULL will leave it unchanged in the client.

Changing these values will not affect the player information stored by furnarchy and returned by the world functions.


Generated on Tue Jun 24 12:24:07 2008 for Furnarchy Module by  doxygen 1.5.5