muffin v7.38.8
This commit is contained in:
parent
5e2d8f648b
commit
3e10cbbbf2
51 changed files with 2585 additions and 1972 deletions
|
|
@ -43,6 +43,8 @@ internal sealed class ActiveQuestComponent
|
|||
|
||||
private readonly UiUtils _uiUtils;
|
||||
|
||||
private readonly IObjectTable _objectTable;
|
||||
|
||||
private readonly IClientState _clientState;
|
||||
|
||||
private readonly IChatGui _chatGui;
|
||||
|
|
@ -58,7 +60,7 @@ internal sealed class ActiveQuestComponent
|
|||
return _003CRegexGenerator_g_003EFBB8301322196CF81C64F1652C2FA6E1D6BF3907141F781E9D97ABED51BF056C4__MultipleWhitespaceRegex_0.Instance;
|
||||
}
|
||||
|
||||
public ActiveQuestComponent(QuestController questController, MovementController movementController, CombatController combatController, GatheringController gatheringController, QuestFunctions questFunctions, ICommandManager commandManager, Configuration configuration, QuestRegistry questRegistry, PriorityWindow priorityWindow, UiUtils uiUtils, IClientState clientState, IChatGui chatGui, ILogger<ActiveQuestComponent> logger)
|
||||
public ActiveQuestComponent(QuestController questController, MovementController movementController, CombatController combatController, GatheringController gatheringController, QuestFunctions questFunctions, ICommandManager commandManager, Configuration configuration, QuestRegistry questRegistry, PriorityWindow priorityWindow, UiUtils uiUtils, IObjectTable objectTable, IClientState clientState, IChatGui chatGui, ILogger<ActiveQuestComponent> logger)
|
||||
{
|
||||
_questController = questController;
|
||||
_movementController = movementController;
|
||||
|
|
@ -70,6 +72,7 @@ internal sealed class ActiveQuestComponent
|
|||
_questRegistry = questRegistry;
|
||||
_priorityWindow = priorityWindow;
|
||||
_uiUtils = uiUtils;
|
||||
_objectTable = objectTable;
|
||||
_clientState = clientState;
|
||||
_chatGui = chatGui;
|
||||
_logger = logger;
|
||||
|
|
@ -243,7 +246,7 @@ internal sealed class ActiveQuestComponent
|
|||
Vector4 col = ImGuiColors.ParsedPurple;
|
||||
if (flag)
|
||||
{
|
||||
int num = _clientState.LocalPlayer?.Level ?? 0;
|
||||
int num = _objectTable.LocalPlayer?.Level ?? 0;
|
||||
if (num > 0 && num >= _configuration.Stop.TargetLevel)
|
||||
{
|
||||
col = ImGuiColors.ParsedGreen;
|
||||
|
|
@ -267,7 +270,7 @@ internal sealed class ActiveQuestComponent
|
|||
ImGui.Separator();
|
||||
if (flag)
|
||||
{
|
||||
int num2 = _clientState.LocalPlayer?.Level ?? 0;
|
||||
int num2 = _objectTable.LocalPlayer?.Level ?? 0;
|
||||
text = new ImU8String(14, 1);
|
||||
text.AppendLiteral("Stop at level ");
|
||||
text.AppendFormatted(_configuration.Stop.TargetLevel);
|
||||
|
|
|
|||
|
|
@ -37,6 +37,8 @@ internal sealed class CreationUtilsComponent
|
|||
|
||||
private readonly QuestSelectionWindow _questSelectionWindow;
|
||||
|
||||
private readonly IObjectTable _objectTable;
|
||||
|
||||
private readonly IClientState _clientState;
|
||||
|
||||
private readonly ITargetManager _targetManager;
|
||||
|
|
@ -49,7 +51,7 @@ internal sealed class CreationUtilsComponent
|
|||
|
||||
private readonly ILogger<CreationUtilsComponent> _logger;
|
||||
|
||||
public CreationUtilsComponent(MovementController movementController, GameFunctions gameFunctions, QuestFunctions questFunctions, TerritoryData territoryData, QuestData questData, QuestSelectionWindow questSelectionWindow, IClientState clientState, ITargetManager targetManager, ICondition condition, IGameGui gameGui, Configuration configuration, ILogger<CreationUtilsComponent> logger)
|
||||
public CreationUtilsComponent(MovementController movementController, GameFunctions gameFunctions, QuestFunctions questFunctions, TerritoryData territoryData, QuestData questData, QuestSelectionWindow questSelectionWindow, IObjectTable objectTable, IClientState clientState, ITargetManager targetManager, ICondition condition, IGameGui gameGui, Configuration configuration, ILogger<CreationUtilsComponent> logger)
|
||||
{
|
||||
_movementController = movementController;
|
||||
_gameFunctions = gameFunctions;
|
||||
|
|
@ -57,6 +59,7 @@ internal sealed class CreationUtilsComponent
|
|||
_territoryData = territoryData;
|
||||
_questData = questData;
|
||||
_questSelectionWindow = questSelectionWindow;
|
||||
_objectTable = objectTable;
|
||||
_clientState = clientState;
|
||||
_targetManager = targetManager;
|
||||
_condition = condition;
|
||||
|
|
@ -129,16 +132,16 @@ internal sealed class CreationUtilsComponent
|
|||
handler.AppendFormatted(value);
|
||||
handler.AppendLiteral(")");
|
||||
ImGui.Text(string.Create(provider, ref handler));
|
||||
if (_clientState.LocalPlayer != null)
|
||||
if (_objectTable.LocalPlayer != null)
|
||||
{
|
||||
invariantCulture = CultureInfo.InvariantCulture;
|
||||
IFormatProvider provider2 = invariantCulture;
|
||||
handler = new DefaultInterpolatedStringHandler(10, 1, invariantCulture);
|
||||
handler.AppendLiteral("Distance: ");
|
||||
handler.AppendFormatted((target.Position - _clientState.LocalPlayer.Position).Length(), "F2");
|
||||
handler.AppendFormatted((target.Position - _objectTable.LocalPlayer.Position).Length(), "F2");
|
||||
ImGui.Text(string.Create(provider2, ref handler));
|
||||
ImGui.SameLine();
|
||||
float value2 = target.Position.Y - _clientState.LocalPlayer.Position.Y;
|
||||
float value2 = target.Position.Y - _objectTable.LocalPlayer.Position.Y;
|
||||
invariantCulture = CultureInfo.InvariantCulture;
|
||||
IFormatProvider provider3 = invariantCulture;
|
||||
handler = new DefaultInterpolatedStringHandler(3, 1, invariantCulture);
|
||||
|
|
@ -317,7 +320,7 @@ internal sealed class CreationUtilsComponent
|
|||
|
||||
private void DrawCopyButton()
|
||||
{
|
||||
if (_clientState.LocalPlayer != null)
|
||||
if (_objectTable.LocalPlayer != null)
|
||||
{
|
||||
bool num = ImGuiComponents.IconButton(FontAwesomeIcon.Copy);
|
||||
if (ImGui.IsItemHovered())
|
||||
|
|
@ -328,11 +331,11 @@ internal sealed class CreationUtilsComponent
|
|||
{
|
||||
ImU8String clipboardText = new ImU8String(87, 4);
|
||||
clipboardText.AppendLiteral("\"Position\": {\n \"X\": ");
|
||||
clipboardText.AppendFormatted(_clientState.LocalPlayer.Position.X.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendFormatted(_objectTable.LocalPlayer.Position.X.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendLiteral(",\n \"Y\": ");
|
||||
clipboardText.AppendFormatted(_clientState.LocalPlayer.Position.Y.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendFormatted(_objectTable.LocalPlayer.Position.Y.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendLiteral(",\n \"Z\": ");
|
||||
clipboardText.AppendFormatted(_clientState.LocalPlayer.Position.Z.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendFormatted(_objectTable.LocalPlayer.Position.Z.ToString(CultureInfo.InvariantCulture));
|
||||
clipboardText.AppendLiteral("\n},\n\"TerritoryId\": ");
|
||||
clipboardText.AppendFormatted(_clientState.TerritoryType);
|
||||
clipboardText.AppendLiteral(",\n\"InteractionType\": \"\"");
|
||||
|
|
@ -340,7 +343,7 @@ internal sealed class CreationUtilsComponent
|
|||
}
|
||||
else if (ImGui.IsItemClicked(ImGuiMouseButton.Right))
|
||||
{
|
||||
Vector3 position = _clientState.LocalPlayer.Position;
|
||||
Vector3 position = _objectTable.LocalPlayer.Position;
|
||||
IFormatProvider invariantCulture = CultureInfo.InvariantCulture;
|
||||
DefaultInterpolatedStringHandler handler = new DefaultInterpolatedStringHandler(12, 3, invariantCulture);
|
||||
handler.AppendLiteral("new(");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue