>heal and >plant are now correctly using currency name/sign. closes #202
This commit is contained in:
parent
d8e0883b33
commit
cf5e89d6a2
@ -70,13 +70,13 @@ namespace NadekoBot.Commands
|
|||||||
var file = Directory.GetFiles("data/currency_images").OrderBy(s => rng.Next()).FirstOrDefault();
|
var file = Directory.GetFiles("data/currency_images").OrderBy(s => rng.Next()).FirstOrDefault();
|
||||||
Message msg;
|
Message msg;
|
||||||
if (file == null)
|
if (file == null)
|
||||||
msg = e.Channel.SendMessage("🌸").Result;
|
msg = e.Channel.SendMessage(NadekoBot.Config.CurrencySign).GetAwaiter().GetResult();
|
||||||
else
|
else
|
||||||
msg = e.Channel.SendFile(file).Result;
|
msg = e.Channel.SendFile(file).GetAwaiter().GetResult();
|
||||||
plantedFlowerChannels.TryAdd(e.Channel.Id, msg);
|
plantedFlowerChannels.TryAdd(e.Channel.Id, msg);
|
||||||
}
|
}
|
||||||
|
var vowelFirst = new[] { 'a', 'e', 'i', 'o', 'u' }.Contains(NadekoBot.Config.CurrencyName[0]);
|
||||||
var msg2 = await e.Channel.SendMessage($"Oh how Nice! **{e.User.Name}** planted a flower. Pick it using {Module.Prefix}pick");
|
var msg2 = await e.Channel.SendMessage($"Oh how Nice! **{e.User.Name}** planted {(vowelFirst ? "an" : "a")} {NadekoBot.Config.CurrencyName}. Pick it using {Module.Prefix}pick");
|
||||||
await Task.Delay(20000);
|
await Task.Delay(20000);
|
||||||
await msg2.Delete();
|
await msg2.Delete();
|
||||||
});
|
});
|
||||||
|
@ -252,7 +252,8 @@ namespace NadekoBot.Modules.Pokemon
|
|||||||
await e.Channel.SendMessage($"{e.User.Name} revived {usr.Name} with one {NadekoBot.Config.CurrencySign}");
|
await e.Channel.SendMessage($"{e.User.Name} revived {usr.Name} with one {NadekoBot.Config.CurrencySign}");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
await e.Channel.SendMessage($"{e.User.Name} healed {usr.Name} for {targetStats.MaxHp - HP} HP with a 🌸");
|
var vowelFirst = new[] { 'a', 'e', 'i', 'o', 'u' }.Contains(NadekoBot.Config.CurrencyName[0]);
|
||||||
|
await e.Channel.SendMessage($"{e.User.Name} healed {usr.Name} for {targetStats.MaxHp - HP} HP with {(vowelFirst ? "an" : "a")} {NadekoBot.Config.CurrencySign}");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user