1. i need add reference in my plugin its names Telegram.bot
    but i have this error
    Error while compiling: Clinet.cs(8,7): error CS0246: The type or namespace name `Telegram' could not be found. Are you missing an assembly reference?
    my simple code is
    Code:
    using Oxide.Core.Libraries.Covalence;
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using UnityEngine;
    using Telegram.Bot;
    namespace Oxide.Plugins
    {
        [Info("", "", "")]
        [Description("")]
        class Clinet : HurtworldPlugin
        {
        
            [ChatCommand("telegarm")]
            void start(PlayerSession session, string command, string[] args)
            {
                TelegramBotClient nn = new TelegramBotClient("TOKEN HERE");
                hurt.SendChatMessage(session, "<color=#ffa500ff>adadsad</color>", "sad");
                nn.SendTextMessageAsync("@er132", "456");
                hurt.BroadcastChat("asd", "sad");
            
                    
            
            }
        }
    }
    help me !!
     
    Last edited by a moderator: May 30, 2018
  2. Wulf

    Wulf Community Admin

    // Reference: DLLname

    At the top of the plugin.
     
  3. tnx man you make best
    [DOUBLEPOST=1527712811][/DOUBLEPOST]Reference System.Net.Http.dll from Telegram.Bot.dll not found
    Added '// Reference: Telegram.Bot' in plugin 'Clinet'
    Error while compiling: Clinet.cs(25,16): error CS7069: Reference to type `System.Threading.CancellationToken' claims it is defined assembly `mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089', but it could not be found


    help me
     
    Last edited by a moderator: May 30, 2018
  4. Wulf

    Wulf Community Admin

    "Reference System.Net.Http.dll from Telegram.Bot.dll not found"

    That should tell you the issue there, you're missing another DLL.
     
  5. fixed i added a refrence but this error
    plugin 'Clinet'
    Error while compiling: Clinet.cs(25,16): error CS7069: Reference to type `System.Threading.CancellationToken' claims it is defined assembly `mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089', but it could not be found
    [DOUBLEPOST=1527715874][/DOUBLEPOST]actually mscorlib is good standing but idk what this error happend
     
  6. Wulf

    Wulf Community Admin

    mscorlib comes with the game, but you're likely trying to mix .NET versions. Hurtworld uses .NET 3.5, so if the DLLs you are using don't support that, then what you are trying to do won't work.