SharpMod.Message.GetUserMessageID C# (CSharp) Method

GetUserMessageID() public static method

Calls the Engine to retrieve the User Message ID
public static GetUserMessageID ( string name ) : int
name string /// The name of the message ///
return int
        public static int GetUserMessageID(string name)
        {
            return MetaModEngine.metaUtilityFunctions.GetUserMsgID(MetaModEngine.PLID, name, 0);
        }

Usage Example

Beispiel #1
0
 public static void ShowMenu(this Player player, short keys, char displaytime, byte multipart, string text)
 {
     Message.Begin(MessageDestination.OneReliable, Message.GetUserMessageID("ShowMenu"), IntPtr.Zero, player.Pointer);
     Message.Write(keys);
     Message.Write(displaytime);
     Message.Write(multipart);
     Message.Write(text);
     Message.End();
 }