Echo Hollow

Gender-Bending Interactive Stories! :D

User Tools

Site Tools


smutbook:classes:util:messagequeue

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
smutbook:classes:util:messagequeue [2023/08/06 20:32] – created leesmutbook:classes:util:messagequeue [2026/08/25 13:58] (current) lee
Line 3: Line 3:
 A global message queue system to allow the story author to more easily hook into the Inventory and Apparel UIs and display various flavor texts and do other processing while a player is fooling around with Inventory and Apparel. A global message queue system to allow the story author to more easily hook into the Inventory and Apparel UIs and display various flavor texts and do other processing while a player is fooling around with Inventory and Apparel.
  
-FIXME Not fully implemented.  May change as we rejigger the UIs.  Maybe ought to move from here to the UI classes.+FIXME May change as we rejigger the UIs.  Maybe ought to move from here to the Inventory UI classes.
  
 ===== MessageQueue.push( message ) ===== ===== MessageQueue.push( message ) =====
  
-If the queue is enabled, push a message into the top of the queue.\\+If the queue is enabled, push a message into the top of the queue. 
 + 
 +**Returns:** void 
 + 
 +===== MessageQueue.unshift( message ) ===== 
 + 
 +If the queue is enabled, push a message onto the bottom of the queue. 
 **Returns:** void **Returns:** void
  
 ===== MessageQueue.shift() ===== ===== MessageQueue.shift() =====
  
-If the queue is enabled, shift a message off the bottom of the queue.\\+If the queue is enabled, shift a message off the bottom of the queue. 
 **Returns:** the message being shifted off, or null if the queue is disabled. **Returns:** the message being shifted off, or null if the queue is disabled.
  
 ===== MessageQueue.dump( separator="\n" ) ===== ===== MessageQueue.dump( separator="\n" ) =====
  
-Dump the whole queue as a string, using the given separator.  Clear the queue.\\+Dump the whole queue as a string, using the given separator.  Clear the queue. 
 **Returns:** the whole queue as a single string **Returns:** the whole queue as a single string
  
Line 23: Line 32:
  
 If the queue is already enabled, to nothing.  Otherwise enable the queue, filling it with the given array of strings. If the queue is already enabled, to nothing.  Otherwise enable the queue, filling it with the given array of strings.
 +
 **Returns:** void **Returns:** void
  
Line 28: Line 38:
  
 Disable and clear the queue. Disable and clear the queue.
 +
 **Returns:** the contents of the queue before it was cleared. **Returns:** the contents of the queue before it was cleared.
  
smutbook/classes/util/messagequeue.1691379141.txt.gz · Last modified: by lee