mirror of
https://github.com/appinfosapienza/so-un-bot.git
synced 2025-05-07 09:19:36 +02:00
Adapt to new bot structure
This commit is contained in:
parent
ff7e08ada9
commit
3f84e1d831
3414 changed files with 41525 additions and 709 deletions
|
@ -1,39 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace SoUnBot.Modules.OttoLinux
|
||||
{
|
||||
public class Question
|
||||
{
|
||||
[JsonProperty("quest")]
|
||||
public String Quest { get; set; }
|
||||
[JsonProperty("answers")]
|
||||
public List<string> Answers { get; }
|
||||
[JsonProperty("correct")]
|
||||
public int Correct { get; private set; }
|
||||
[JsonProperty("image")]
|
||||
public string Image { get; private set; }
|
||||
|
||||
public Question(String quest)
|
||||
{
|
||||
Quest = quest;
|
||||
Answers = new List<string>();
|
||||
Correct = 0;
|
||||
}
|
||||
|
||||
public void AddAnswer(String answer, bool correct)
|
||||
{
|
||||
Answers.Add(answer);
|
||||
Correct = correct ? Answers.Count - 1 : Correct;
|
||||
}
|
||||
|
||||
public void Append(String quest)
|
||||
{
|
||||
Quest += quest;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue