C# Class IdleLandsRedux.GameLogic.Managers.MessageManager

Inheritance: IMessageManager
Exibir arquivo Open project: IdleLands/IdleLandsRedux Class Usage Examples

Private Properties

Property Type Description
GetRandomLineOfFile string
ReplaceWithLineIfContains StringBuilder

Public Methods

Method Description
MessageManager ( IRandomHelper randomHelper ) : System
ParseAndReplaceEventMessage ( string eventMessage, int goldGained, int xpGained, IdleLandsRedux.DataAccess.Mappings.Player player = null, Item item = null ) : string

Parses and replace the event message. See https://github.com/IdleLands/IdleLands/blob/master/docs/EVENTVAR.md for possible variables.

Private Methods

Method Description
GetRandomLineOfFile ( string filepath ) : string
ReplaceWithLineIfContains ( StringBuilder builder, string input, string contains, string filepath ) : StringBuilder

Method Details

MessageManager() public method

public MessageManager ( IRandomHelper randomHelper ) : System
randomHelper IRandomHelper
return System

ParseAndReplaceEventMessage() public method

Parses and replace the event message. See https://github.com/IdleLands/IdleLands/blob/master/docs/EVENTVAR.md for possible variables.
public ParseAndReplaceEventMessage ( string eventMessage, int goldGained, int xpGained, IdleLandsRedux.DataAccess.Mappings.Player player = null, Item item = null ) : string
eventMessage string Event message.
goldGained int Gold gained.
xpGained int Xp gained.
player IdleLandsRedux.DataAccess.Mappings.Player Player.
item Item Item.
return string