mirror of
https://gitgud.io/Ed86/rjw-whoring.git
synced 2024-08-15 00:03:25 +00:00
1.0
This commit is contained in:
parent
305c62a991
commit
d56c5016f8
7 changed files with 38 additions and 18 deletions
Binary file not shown.
|
@ -3,7 +3,6 @@
|
|||
<PawnColumnDef>
|
||||
<defName>RJW_IsWhore</defName>
|
||||
<headerTip>Whores</headerTip>
|
||||
<headerIcon>UI/Tab/Service_off</headerIcon>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_IsWhore</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>80</width>
|
||||
|
@ -11,7 +10,6 @@
|
|||
<PawnColumnDef>
|
||||
<defName>RJW_IsPrisoner</defName>
|
||||
<headerTip>Prisoners</headerTip>
|
||||
<headerIcon>UI/Tab/ComfortPrisoner_off</headerIcon>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_IsPrisoner</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>80</width>
|
||||
|
@ -19,7 +17,6 @@
|
|||
<PawnColumnDef>
|
||||
<defName>RJW_IsSlave</defName>
|
||||
<headerTip>Slaves</headerTip>
|
||||
<headerIcon>UI/Tab/ComfortPrisoner_off</headerIcon>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_IsSlave</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>80</width>
|
||||
|
@ -29,7 +26,6 @@
|
|||
<headerTip>Whoring experience</headerTip>
|
||||
<label>Experience</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_WhoreExperience</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
<PawnColumnDef>
|
||||
|
@ -37,7 +33,6 @@
|
|||
<headerTip>Price range for whore</headerTip>
|
||||
<label>Price</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_PriceRangeOfWhore</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
<PawnColumnDef>
|
||||
|
@ -45,7 +40,6 @@
|
|||
<headerTip>Money earned(total)</headerTip>
|
||||
<label>Earned</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_EarnedMoneyByWhore</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
<PawnColumnDef>
|
||||
|
@ -53,7 +47,6 @@
|
|||
<headerTip>Clients served</headerTip>
|
||||
<label>Clients</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_CountOfWhore</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
<PawnColumnDef>
|
||||
|
@ -61,7 +54,6 @@
|
|||
<headerTip>Money earned(average)</headerTip>
|
||||
<label>Average</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_AverageMoneyByWhore</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
<PawnColumnDef>
|
||||
|
@ -69,7 +61,6 @@
|
|||
<headerTip>Mood of pawn</headerTip>
|
||||
<label>Mood</label>
|
||||
<workerClass>rjwwhoring.MainTab.PawnColumnWorker_Mood</workerClass>
|
||||
<sortable>true</sortable>
|
||||
<width>100</width>
|
||||
</PawnColumnDef>
|
||||
</Defs>
|
||||
|
|
|
@ -36,4 +36,6 @@
|
|||
<WhorePriceCalcDesc>Whoring price factor (based on comfort, room impressiveness and number of beds in room: {0}</WhorePriceCalcDesc>
|
||||
|
||||
<WhorePrice>Whoring price range: </WhorePrice>
|
||||
<BrothelTabIsPrisoner>Prisoner</BrothelTabIsPrisoner>
|
||||
<BrothelTabIsSlave>Slave</BrothelTabIsSlave>
|
||||
</LanguageData>
|
|
@ -14,10 +14,21 @@ namespace rjwwhoring.MainTab
|
|||
{
|
||||
private static readonly Texture2D comfortOn = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_on");
|
||||
private readonly Texture2D comfortOff = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_off");
|
||||
private readonly Texture2D comfortOff_nobg = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_off_nobg");
|
||||
|
||||
protected override Texture2D GetIconFor(Pawn pawn)
|
||||
{
|
||||
return pawn.IsPrisonerOfColony ? comfortOn : null;
|
||||
return pawn.IsPrisonerOfColony ? comfortOff_nobg : null;
|
||||
}
|
||||
protected override string GetIconTip(Pawn pawn)
|
||||
{
|
||||
//string str = (pawn != null) ? pawn.guest.GetLabel() : null;
|
||||
//if (!str.NullOrEmpty())
|
||||
//{
|
||||
// return str.CapitalizeFirst();
|
||||
//}
|
||||
//return null;
|
||||
return "BrothelTabIsPrisoner".Translate();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -14,10 +14,22 @@ namespace rjwwhoring.MainTab
|
|||
{
|
||||
private static readonly Texture2D comfortOn = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_on");
|
||||
private readonly Texture2D comfortOff = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_off");
|
||||
|
||||
private readonly Texture2D comfortOff_nobg = ContentFinder<Texture2D>.Get("UI/Tab/ComfortPrisoner_off_nobg");
|
||||
protected override Texture2D GetIconFor(Pawn pawn)
|
||||
{
|
||||
return xxx.is_slave(pawn) ? comfortOn : null;
|
||||
return xxx.is_slave(pawn) ? ModsConfig.IdeologyActive ? GuestUtility.SlaveIcon : comfortOff_nobg : null;
|
||||
//return xxx.is_slave(pawn) ? comfortOff : null;
|
||||
}
|
||||
protected override string GetIconTip(Pawn pawn)
|
||||
{
|
||||
//string str = (pawn != null) ? pawn.guest.GetLabel() : null;
|
||||
//if (!str.NullOrEmpty())
|
||||
//{
|
||||
// return str.CapitalizeFirst();
|
||||
//}
|
||||
//return null;
|
||||
return "BrothelTabIsSlave".Translate();
|
||||
;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -7,23 +7,27 @@ using Verse;
|
|||
|
||||
namespace rjwwhoring.MainTab
|
||||
{
|
||||
public class PawnTable_Whores : PawnTable
|
||||
public class PawnTable_Whores : PawnTable_PlayerPawns
|
||||
{
|
||||
public PawnTable_Whores(PawnTableDef def, Func<IEnumerable<Pawn>> pawnsGetter, int uiWidth, int uiHeight) : base(def, pawnsGetter, uiWidth, uiHeight) { }
|
||||
|
||||
//default sorting
|
||||
protected override IEnumerable<Pawn> LabelSortFunction(IEnumerable<Pawn> input)
|
||||
{
|
||||
//return input.OrderBy(p => p.Name?.Numerical != false).ThenBy(p => (p.Name as NameSingle)?.Number ?? 0).ThenBy(p => p.def.label);
|
||||
return input.OrderBy(p => xxx.get_pawnname(p));
|
||||
//return input.OrderBy(p => p.Name);
|
||||
foreach (Pawn p in input)
|
||||
p.UpdatePermissions();
|
||||
return input.OrderByDescending(p => (p.IsPrisonerOfColony || p.IsSlaveOfColony) != false).ThenBy(p => xxx.get_pawnname(p));
|
||||
//return input.OrderByDescending(p => (p.IsPrisonerOfColony || p.IsSlaveOfColony) != false).ThenBy(p => (p.Name.ToStringShort.Colorize(Color.yellow)));
|
||||
//return input.OrderBy(p => xxx.get_pawnname(p));
|
||||
}
|
||||
|
||||
protected override IEnumerable<Pawn> PrimarySortFunction(IEnumerable<Pawn> input)
|
||||
{
|
||||
///return input.OrderByDescending(p => p.Faction?.Name);
|
||||
//return input.OrderBy(p => xxx.get_pawnname(p));
|
||||
foreach (Pawn p in input)
|
||||
p.UpdatePermissions();
|
||||
return input.OrderByDescending(p => p.IsColonist);
|
||||
return input;
|
||||
//return base.PrimarySortFunction(input);
|
||||
}
|
||||
}
|
||||
}
|
BIN
1.3/Textures/UI/Tab/ComfortPrisoner_off_nobg.png
Normal file
BIN
1.3/Textures/UI/Tab/ComfortPrisoner_off_nobg.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 7.4 KiB |
Loading…
Reference in a new issue