mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-21 12:19:15 +12:00
Add profiles
This commit is contained in:
parent
4758fd0200
commit
524c7f2214
7 changed files with 295 additions and 63 deletions
|
@ -339,6 +339,15 @@ namespace HISP.Game
|
|||
public static string RakeNothing;
|
||||
public static string ShovelNothing;
|
||||
|
||||
// Pronouns
|
||||
public static string PronounMaleHe;
|
||||
public static string PronounMaleHis;
|
||||
|
||||
public static string PronounFemaleShe;
|
||||
public static string PronounFemaleHer;
|
||||
|
||||
public static string PronounYouYour;
|
||||
|
||||
// Stats Page
|
||||
public static string StatsBarFormat;
|
||||
public static string StatsAreaFormat;
|
||||
|
@ -359,11 +368,21 @@ namespace HISP.Game
|
|||
public static string JewelrySlot3Format;
|
||||
public static string JewelrySlot4Format;
|
||||
|
||||
public static string JewelryRemoveSlot1Button;
|
||||
public static string JewelryRemoveSlot2Button;
|
||||
public static string JewelryRemoveSlot3Button;
|
||||
public static string JewelryRemoveSlot4Button;
|
||||
|
||||
public static string CompetitionGearHeadFormat;
|
||||
public static string CompetitionGearBodyFormat;
|
||||
public static string CompetitionGearLegsFormat;
|
||||
public static string CompetitionGearFeetFormat;
|
||||
|
||||
public static string CompetitionGearRemoveHeadButton;
|
||||
public static string CompetitionGearRemoveBodyButton;
|
||||
public static string CompetitionGearRemoveLegsButton;
|
||||
public static string CompetitionGearRemoveFeetButton;
|
||||
|
||||
public static string StatsPrivateNotesButton;
|
||||
public static string StatsQuestsButton;
|
||||
public static string StatsMinigameRankingButton;
|
||||
|
@ -371,14 +390,23 @@ namespace HISP.Game
|
|||
public static string StatsMiscButton;
|
||||
|
||||
public static string NoJewerlyEquipped;
|
||||
public static string NoJewerlyEquippedOther;
|
||||
|
||||
public static string NoCompetitionGear;
|
||||
public static string NoCompetitionGearOther;
|
||||
|
||||
public static string JewelrySelected;
|
||||
public static string JewelrySelectedOther;
|
||||
|
||||
public static string CompetitionGearSelected;
|
||||
public static string CompetitionGearSelectedOther;
|
||||
|
||||
public static string StatHunger;
|
||||
public static string StatThirst;
|
||||
public static string StatTired;
|
||||
|
||||
public static string StatsOtherHorses;
|
||||
|
||||
public static string[] StatPlayerFormats;
|
||||
|
||||
// Misc Stats
|
||||
|
@ -992,6 +1020,28 @@ namespace HISP.Game
|
|||
// Click
|
||||
public static string NothingInterestingHere;
|
||||
|
||||
|
||||
public static string FormatOtherNoCompetitionGear(string pronoun)
|
||||
{
|
||||
return NoCompetitionGearOther.Replace("%PRONOUN%", pronoun);
|
||||
}
|
||||
public static string FormatOtherCompetitionGear(string pronoun)
|
||||
{
|
||||
return CompetitionGearSelectedOther.Replace("%PRONOUN%", pronoun);
|
||||
}
|
||||
public static string FormatOtherJewelerySelected(string pronoun)
|
||||
{
|
||||
return JewelrySelectedOther.Replace("%PRONOUN%", pronoun);
|
||||
}
|
||||
public static string FormatOtherNoJewelery(string pronoun)
|
||||
{
|
||||
return NoJewerlyEquippedOther.Replace("%PRONOUN%", pronoun);
|
||||
}
|
||||
public static string FormatOtherHorsesMeta(string pronoun)
|
||||
{
|
||||
return StatsOtherHorses.Replace("%PRONOUN%", pronoun);
|
||||
}
|
||||
|
||||
// Socials
|
||||
public static string FormatSocialButton(int socialId, string buttonName)
|
||||
{
|
||||
|
@ -2095,38 +2145,38 @@ namespace HISP.Game
|
|||
{
|
||||
return statFormat.Replace("%STAT%", statName);
|
||||
}
|
||||
public static string FormatJewelrySlot1(string itemName, int icon)
|
||||
public static string FormatJewelrySlot1(string itemName, int icon, bool other)
|
||||
{
|
||||
return JewelrySlot1Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return JewelrySlot1Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%BUTTON%", other ? "" : Messages.JewelryRemoveSlot1Button);
|
||||
}
|
||||
public static string FormatJewelrySlot2(string itemName, int icon)
|
||||
public static string FormatJewelrySlot2(string itemName, int icon, bool other)
|
||||
{
|
||||
return JewelrySlot2Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return JewelrySlot2Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%BUTTON%", other ? "" : Messages.JewelryRemoveSlot2Button);
|
||||
}
|
||||
public static string FormatJewelrySlot3(string itemName, int icon)
|
||||
public static string FormatJewelrySlot3(string itemName, int icon, bool other)
|
||||
{
|
||||
return JewelrySlot3Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return JewelrySlot3Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%BUTTON%", other ? "" : Messages.JewelryRemoveSlot3Button);
|
||||
}
|
||||
public static string FormatJewelrySlot4(string itemName, int icon)
|
||||
public static string FormatJewelrySlot4(string itemName, int icon, bool other)
|
||||
{
|
||||
return JewelrySlot4Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return JewelrySlot4Format.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%BUTTON%", other ? "" : Messages.JewelryRemoveSlot4Button);
|
||||
}
|
||||
|
||||
public static string FormatCompetitionGearHead(string itemName, int icon)
|
||||
public static string FormatCompetitionGearHead(string itemName, string pronoun, int icon, bool other)
|
||||
{
|
||||
return CompetitionGearHeadFormat.Replace("%ITEM%", itemName).Replace("%ICON%",icon.ToString());
|
||||
return CompetitionGearHeadFormat.Replace("%ITEM%", itemName).Replace("%ICON%",icon.ToString()).Replace("%PRONOUN%", pronoun) + (other ? "" : Messages.CompetitionGearRemoveHeadButton);
|
||||
}
|
||||
public static string FormatCompetitionGearBody(string itemName, int icon)
|
||||
public static string FormatCompetitionGearBody(string itemName, string pronoun, int icon, bool other)
|
||||
{
|
||||
return CompetitionGearBodyFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return CompetitionGearBodyFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%PRONOUN%", pronoun) + (other ? "" : Messages.CompetitionGearRemoveBodyButton); ;
|
||||
}
|
||||
public static string FormatCompetitionGearLegs(string itemName, int icon)
|
||||
public static string FormatCompetitionGearLegs(string itemName, string pronoun, int icon, bool other)
|
||||
{
|
||||
return CompetitionGearLegsFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return CompetitionGearLegsFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%PRONOUN%", pronoun) + (other ? "" : Messages.CompetitionGearRemoveLegsButton);
|
||||
}
|
||||
public static string FormatCompetitionGearFeet(string itemName, int icon)
|
||||
public static string FormatCompetitionGearFeet(string itemName, string pronoun, int icon, bool other)
|
||||
{
|
||||
return CompetitionGearFeetFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString());
|
||||
return CompetitionGearFeetFormat.Replace("%ITEM%", itemName).Replace("%ICON%", icon.ToString()).Replace("%PRONOUN%", pronoun) + (other ? "" : Messages.CompetitionGearRemoveFeetButton );
|
||||
}
|
||||
public static string FormatStatsBar(string username)
|
||||
{
|
||||
|
|
|
@ -246,20 +246,59 @@ namespace HISP.Game
|
|||
return message;
|
||||
}
|
||||
|
||||
private static string buildWornJewelery(User user)
|
||||
private static string buildWornJewelery(User user, bool other)
|
||||
{
|
||||
string message = Messages.JewelrySelected;
|
||||
if (user.EquipedJewelry.Slot1 != null)
|
||||
message += Messages.FormatJewelrySlot1(user.EquipedJewelry.Slot1.Name, user.EquipedJewelry.Slot1.IconId);
|
||||
if (user.EquipedJewelry.Slot2 != null)
|
||||
message += Messages.FormatJewelrySlot2(user.EquipedJewelry.Slot2.Name, user.EquipedJewelry.Slot2.IconId);
|
||||
if (user.EquipedJewelry.Slot3 != null)
|
||||
message += Messages.FormatJewelrySlot3(user.EquipedJewelry.Slot3.Name, user.EquipedJewelry.Slot3.IconId);
|
||||
if (user.EquipedJewelry.Slot4 != null)
|
||||
message += Messages.FormatJewelrySlot4(user.EquipedJewelry.Slot4.Name, user.EquipedJewelry.Slot4.IconId);
|
||||
string message = "";
|
||||
|
||||
// Insert LGBT Patch here
|
||||
|
||||
string pronoun = "";
|
||||
if (other)
|
||||
{
|
||||
if (user.Gender == "FEMALE")
|
||||
pronoun = Messages.PronounFemaleShe;
|
||||
|
||||
if (user.Gender == "MALE")
|
||||
pronoun = Messages.PronounMaleHe;
|
||||
}
|
||||
|
||||
if (!other)
|
||||
message += Messages.JewelrySelected;
|
||||
else
|
||||
message += Messages.FormatOtherJewelerySelected(pronoun);
|
||||
|
||||
bool hasMsg = false;
|
||||
|
||||
if (user.EquipedJewelry.Slot1 != null)
|
||||
{
|
||||
message += Messages.FormatJewelrySlot1(user.EquipedJewelry.Slot1.Name, user.EquipedJewelry.Slot1.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedJewelry.Slot2 != null)
|
||||
{
|
||||
message += Messages.FormatJewelrySlot2(user.EquipedJewelry.Slot2.Name, user.EquipedJewelry.Slot2.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedJewelry.Slot3 != null)
|
||||
{
|
||||
message += Messages.FormatJewelrySlot3(user.EquipedJewelry.Slot3.Name, user.EquipedJewelry.Slot3.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedJewelry.Slot4 != null)
|
||||
{
|
||||
message += Messages.FormatJewelrySlot4(user.EquipedJewelry.Slot4.Name, user.EquipedJewelry.Slot4.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
|
||||
if (!hasMsg)
|
||||
{
|
||||
if (!other)
|
||||
message = Messages.NoJewerlyEquipped;
|
||||
else
|
||||
message = Messages.FormatOtherNoJewelery(pronoun);
|
||||
}
|
||||
|
||||
|
||||
if (message == Messages.JewelrySelected)
|
||||
message = Messages.NoJewerlyEquipped;
|
||||
|
||||
return message;
|
||||
}
|
||||
|
@ -297,20 +336,57 @@ namespace HISP.Game
|
|||
message += Messages.MetaTerminator;
|
||||
return message;
|
||||
}
|
||||
private static string buildEquippedCompetitionGear(User user)
|
||||
private static string buildEquippedCompetitionGear(User user, bool other = false)
|
||||
{
|
||||
string message = Messages.CompetitionGearSelected;
|
||||
if (user.EquipedCompetitionGear.Head != null)
|
||||
message += Messages.FormatCompetitionGearHead(user.EquipedCompetitionGear.Head.Name, user.EquipedCompetitionGear.Head.IconId);
|
||||
if (user.EquipedCompetitionGear.Body != null)
|
||||
message += Messages.FormatCompetitionGearBody(user.EquipedCompetitionGear.Body.Name, user.EquipedCompetitionGear.Body.IconId);
|
||||
if (user.EquipedCompetitionGear.Legs != null)
|
||||
message += Messages.FormatCompetitionGearLegs(user.EquipedCompetitionGear.Legs.Name, user.EquipedCompetitionGear.Legs.IconId);
|
||||
if (user.EquipedCompetitionGear.Feet != null)
|
||||
message += Messages.FormatCompetitionGearFeet(user.EquipedCompetitionGear.Feet.Name, user.EquipedCompetitionGear.Feet.IconId);
|
||||
string message = "";
|
||||
|
||||
if (message == Messages.CompetitionGearSelected)
|
||||
message = Messages.NoCompetitionGear;
|
||||
if (!other)
|
||||
message = Messages.CompetitionGearSelected;
|
||||
|
||||
// Insert LGBT Patch Here
|
||||
|
||||
string pronoun = Messages.PronounYouYour;
|
||||
if(other)
|
||||
{
|
||||
if (user.Gender == "FEMALE")
|
||||
pronoun = Messages.PronounFemaleShe;
|
||||
|
||||
if (user.Gender == "MALE")
|
||||
pronoun = Messages.PronounMaleHe;
|
||||
|
||||
message = Messages.FormatOtherCompetitionGear(pronoun);
|
||||
}
|
||||
|
||||
bool hasMsg = false;
|
||||
|
||||
if (user.EquipedCompetitionGear.Head != null)
|
||||
{
|
||||
message += Messages.FormatCompetitionGearHead(user.EquipedCompetitionGear.Head.Name, pronoun, user.EquipedCompetitionGear.Head.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedCompetitionGear.Body != null)
|
||||
{
|
||||
message += Messages.FormatCompetitionGearBody(user.EquipedCompetitionGear.Body.Name, pronoun, user.EquipedCompetitionGear.Body.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedCompetitionGear.Legs != null)
|
||||
{
|
||||
message += Messages.FormatCompetitionGearLegs(user.EquipedCompetitionGear.Legs.Name, pronoun, user.EquipedCompetitionGear.Legs.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
if (user.EquipedCompetitionGear.Feet != null)
|
||||
{
|
||||
message += Messages.FormatCompetitionGearFeet(user.EquipedCompetitionGear.Feet.Name, pronoun, user.EquipedCompetitionGear.Feet.IconId, other);
|
||||
hasMsg = true;
|
||||
}
|
||||
|
||||
if (!hasMsg)
|
||||
{
|
||||
if (!other)
|
||||
message = Messages.NoCompetitionGear;
|
||||
else
|
||||
message = Messages.FormatOtherNoCompetitionGear(pronoun);
|
||||
}
|
||||
|
||||
return message;
|
||||
|
||||
|
@ -897,14 +973,15 @@ namespace HISP.Game
|
|||
message += Messages.MetaTerminator;
|
||||
return message;
|
||||
}
|
||||
public static string BuildStatsMenu(User user)
|
||||
public static string BuildStatsMenu(User user, bool other=false)
|
||||
{
|
||||
string message = Messages.FormatStatsBar(user.Username);
|
||||
|
||||
string areaString = buildAreaString(user.X, user.Y);
|
||||
if (areaString != "")
|
||||
message += Messages.FormatStatsArea(areaString);
|
||||
message += Messages.FormatMoneyStat(user.Money);
|
||||
if(!other)
|
||||
message += Messages.FormatMoneyStat(user.Money);
|
||||
if (!user.Subscribed)
|
||||
message += Messages.FormatFreeTime(user.FreeMinutes);
|
||||
message += Messages.FormatPlayerDescriptionForStatsMenu(user.ProfilePage);
|
||||
|
@ -913,13 +990,36 @@ namespace HISP.Game
|
|||
message += Messages.FormatThirstStat(Messages.FormatPlayerStat(SelectPlayerStatFormat(user.Thirst), Messages.StatThirst));
|
||||
message += Messages.FormatTiredStat(Messages.FormatPlayerStat(SelectPlayerStatFormat(user.Tiredness), Messages.StatTired));
|
||||
message += Messages.FormatGenderStat(user.Gender);
|
||||
message += Messages.FormatJewelryStat(buildWornJewelery(user));
|
||||
message += Messages.FormatCompetitionGearStat(buildEquippedCompetitionGear(user));
|
||||
message += Messages.StatsPrivateNotesButton;
|
||||
message += Messages.StatsQuestsButton;
|
||||
message += Messages.StatsMinigameRankingButton;
|
||||
message += Messages.StatsAwardsButton;
|
||||
message += Messages.StatsMiscButton;
|
||||
message += Messages.FormatJewelryStat(buildWornJewelery(user, other));
|
||||
message += Messages.FormatCompetitionGearStat(buildEquippedCompetitionGear(user, other));
|
||||
|
||||
if(!other)
|
||||
{
|
||||
message += Messages.StatsPrivateNotesButton;
|
||||
message += Messages.StatsQuestsButton;
|
||||
message += Messages.StatsMinigameRankingButton;
|
||||
message += Messages.StatsAwardsButton;
|
||||
message += Messages.StatsMiscButton;
|
||||
}
|
||||
else
|
||||
{
|
||||
// Insert LGBT Patch here
|
||||
|
||||
string pronoun = "";
|
||||
if (other)
|
||||
{
|
||||
if (user.Gender == "FEMALE")
|
||||
pronoun = Messages.PronounFemaleHer;
|
||||
|
||||
if (user.Gender == "MALE")
|
||||
pronoun = Messages.PronounMaleHis;
|
||||
}
|
||||
|
||||
message += Messages.FormatOtherHorsesMeta(pronoun);
|
||||
|
||||
message += buildHorseList(user, false);
|
||||
}
|
||||
|
||||
|
||||
message += Messages.BackToMap;
|
||||
message += Messages.MetaTerminator;
|
||||
|
|
|
@ -330,11 +330,10 @@ namespace HISP.Game
|
|||
return quest;
|
||||
}
|
||||
}
|
||||
throw new KeyNotFoundException("QuestId: " + id + " Dont exist.");
|
||||
throw new KeyNotFoundException("Quest Id: " + id + " Dont exist.");
|
||||
}
|
||||
public static bool UseTool(User user, string tool, int x, int y)
|
||||
{
|
||||
|
||||
if (tool == Quest.Shovel)
|
||||
{
|
||||
// check Treasures
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue