Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
AM_Adv Class Reference
Inheritance diagram for AM_Adv:
AM_BaseGameMode ActionMode EClass AM_ADV_Target AM_Region

Classes

class  PressedAction
 

Public Member Functions

override bool HighlightWall (Point p)
 
override void OnActivate ()
 
override void OnDeactivate ()
 
override void OnRenderTile (Point point, HitResult result, int dir)
 
override int GetDefaultTile (Point p)
 
override void OnBeforeUpdate ()
 
override void OnAfterUpdate ()
 
override void OnUpdateCursor ()
 
void UpdatePlans ()
 
void UpdateLangWheel ()
 
void ClearPlans ()
 
void OnBecomeNoGoal ()
 
override void _OnUpdateInput ()
 
void ShowAllAction ()
 
void SetTurbo (int mtp=-1)
 
void EndTurbo ()
 
void ToggleZoom ()
 
bool TryCancelInteraction (bool sound=true)
 
bool CanAct ()
 
void AxisMove ()
 
void SetManualMove ()
 
void SetPressedAction (ButtonState button)
 
bool PressedActionMove (Point pos)
 
virtual void RefreshArrow ()
 
- Public Member Functions inherited from AM_BaseGameMode
override void OnUpdateInput ()
 
override string GetHintText ()
 
virtual void _OnUpdateInput ()
 
override void OnCancel ()
 
override HitResult HitTest (Point point, Point start)
 
- Public Member Functions inherited from ActionMode
virtual int TopHeight (Point p)
 
virtual void SEExecuteSummary ()
 
virtual bool HighlightWall (Point p)
 
virtual void OnClickSubMenu (int a)
 
virtual string OnSetSubMenuButton (int a, UIButton b)
 
virtual bool IsRoofEditMode (Card c=null)
 
virtual bool IsFillMode ()
 
virtual int GetDefaultTile (Point p)
 
virtual void OnShowExtraHint (UINote n)
 
void Activate (bool toggle=true, bool forceActivate=false)
 
virtual void OnActivate ()
 
void RefreshTexts ()
 
virtual string GetSimpleText (Card c)
 
void ClearSimpleTexts ()
 
void Deactivate ()
 
virtual void OnDeactivate ()
 
virtual void OnCancel ()
 
virtual void OnBeforeUpdate ()
 
virtual void OnAfterUpdate ()
 
virtual void OnUpdateCursor ()
 
void OnRotate ()
 
void SetCursorOnMap (CursorInfo cursor)
 
void UpdateInput ()
 
void InputMovement ()
 
virtual void InputWheel (int wheel)
 
virtual void OnUpdateInput ()
 
void DoFunc (CoreConfig.GameFuncBuild func)
 
bool IsFuncPressed (CoreConfig.GameFunc func)
 
void DoFunc (CoreConfig.GameFunc func)
 
virtual void OnScroll ()
 
void TryRightClickCloseWidget ()
 
bool TryShowWidgetMenu ()
 
HitResult _HitTest (Point point, Point start)
 
virtual HitResult HitTest (Point point, Point start)
 
virtual void OnSelectStart (Point point)
 
virtual void OnSelectEnd (bool cancel)
 
virtual MeshPass GetGuidePass (Point point)
 
virtual void OnRenderTile (Point point, HitResult result, int dir)
 
void OnRenderTileFloor (Point point, HitResult result)
 
virtual bool CanProcessTiles ()
 
virtual void OnBeforeProcessTiles ()
 
virtual void OnProcessTiles (Point point, int dir)
 
virtual void OnAfterProcessTiles (Point start, Point end)
 
virtual void OnFinishProcessTiles ()
 
virtual void OnRefreshSummary (Point point, HitResult result, HitSummary summary)
 
void ShowLayer ()
 
virtual Layer OnShowLayer ()
 
void HideLayer ()
 
virtual void OnHideLayer ()
 
virtual string GetHintText ()
 
virtual void RotateUnderMouse ()
 
virtual ref string SetMouseInfo (ref string s)
 
void TogglePause ()
 
void Pause (bool sound=false)
 
void UnPause (bool sound=false)
 
void ChangeGameSpeed (int a, bool sound=false)
 

Public Attributes

bool zoomOut
 
bool zoomOut2
 
bool movedByKey
 
int itemLost
 
PressedAction pressedAction = new PressedAction()
 
PointTarget axisTarget
 
ActPlan planLeft
 
ActPlan planRight
 
ActPlan planKeyboard
 
ActPlan planAll
 
string textWheel
 
string textMiddle
 
bool updatePlans
 
bool isMoving
 
float rightMouseTimer
 
- Public Attributes inherited from AM_BaseGameMode
bool isMouseOnMap
 
- Public Attributes inherited from ActionMode
Layer layer
 
int brushRadius = 4
 

Static Public Attributes

static float turbo
 
static int actCount
 
- Static Public Attributes inherited from ActionMode
static ActionMode DefaultMode
 
static AM_Title Title = new AM_Title()
 
static AM_Sim Sim
 
static AM_ViewZone View
 
static AM_Adv Adv
 
static AM_Region Region
 
static AM_ADV_Target AdvTarget
 
static AM_EloMap EloMap
 
static AM_Inspect Inspect
 
static AM_NoMap NoMap
 
static AM_MiniGame MiniGame
 
static AM_NewZone NewZone
 
static AM_Bird Bird
 
static AM_Mine Mine
 
static AM_Dig Dig
 
static AM_Harvest Harvest
 
static AM_Cut Cut
 
static AM_StateEditor StateEditor
 
static AM_Picker Picker
 
static AM_Copy Copy
 
static AM_Blueprint Blueprint
 
static AM_Build Build
 
static AM_CreateArea CreateArea
 
static AM_EditArea EditArea
 
static AM_ExpandArea ExpandArea
 
static AM_Deconstruct Deconstruct
 
static AM_Select Select
 
static AM_RemoveDesignation RemoveDesignation
 
static AM_ViewMap ViewMap
 
static AM_Terrain Terrain
 
static AM_Populate Populate
 
static AM_EditMarker EditMarker
 
static AM_Visibility Visibility
 
static AM_Cinema Cinema
 
static AM_Paint Paint
 
static AM_FlagCell FlagCell
 
static ActionMode LastBuildMode
 
static SourceMaterial.Row lastEditorMat
 
static bool ignoreSound
 
static float[] GameSpeeds = new float[4] { 0f, 1f, 2f, 5f }
 
static List< TCSimpleTextsimpleTexts = new List<TCSimpleText>()
 
static float hotElementTimer
 
- Static Public Attributes inherited from EClass
static Core core
 

Protected Attributes

int arrowIndex
 
float timerStartRunning
 
bool cursorMove
 
bool keepWalking
 
Vector3 posOrigin
 
Vector3 posArrow
 
Vector2 vArrow
 
Vector3 clickPos
 

Properties

PointTarget mouseTarget [get]
 
bool autorun [get]
 
bool ShouldHideTile [get]
 
override float gameSpeed [get]
 
override bool FixFocus [get]
 
override bool ShouldPauseGame [get]
 
override bool AllowWheelZoom [get]
 
override float TargetZoom [get]
 
- Properties inherited from AM_BaseGameMode
override AreaHighlightMode AreaHihlight [get]
 
override bool ShowActionHint [get]
 
override bool HideSubWidgets [get]
 
override BaseTileSelector.HitType hitType [get]
 
override BaseTileSelector.SelectType selectType [get]
 
override BaseGameScreen TargetGameScreen [get]
 
Point hit [get]
 
- Properties inherited from ActionMode
static AM_Adv AdvOrRegion [get]
 
static bool IsAdv [get]
 
virtual float gameSpeed [get]
 
bool IsActive [get]
 
virtual BaseTileSelector.HitType hitType [get]
 
virtual BaseTileSelector.SelectType selectType [get]
 
virtual BaseTileSelector.BoxType boxType [get]
 
virtual bool ContinuousClick [get]
 
virtual int hitW [get]
 
virtual int hitH [get]
 
HitSummary Summary [get]
 
bool Multisize [get]
 
virtual string id [get]
 
virtual CursorInfo DefaultCursor [get]
 
virtual string idHelpTopic [get]
 
virtual string idSound [get]
 
virtual bool enableMouseInfo [get]
 
virtual bool hideBalloon [get]
 
virtual string textHintTitle [get]
 
virtual bool AllowAutoClick [get]
 
virtual bool ShowActionHint [get]
 
virtual bool ShowMouseoverTarget [get]
 
virtual AreaHighlightMode AreaHihlight [get]
 
virtual bool CanSelectTile [get]
 
virtual bool CanTargetOutsideBounds [get]
 
virtual bool ShouldPauseGame [get]
 
virtual bool FixFocus [get]
 
virtual bool HideSubWidgets [get]
 
virtual bool IsBuildMode [get]
 
virtual bool ShowBuildWidgets [get]
 
virtual BuildMenu.Mode buildMenuMode [get]
 
virtual bool ShouldHideBuildMenu [get]
 
virtual bool CanTargetFog [get]
 
virtual int CostMoney [get]
 
virtual bool AllowBuildModeShortcuts [get]
 
virtual bool AllowMiddleClickFunc [get]
 
virtual bool AllowHotbar [get]
 
virtual bool AllowGeneralInput [get]
 
virtual bool ShowMaskedThings [get]
 
virtual int SelectorHeight [get]
 
virtual bool AllowWheelZoom [get]
 
virtual float TargetZoom [get]
 
virtual BaseTileMap.CardIconMode cardIconMode [get]
 
virtual BaseGameScreen TargetGameScreen [get]
 
virtual bool IsNoMap [get]
 
virtual bool UseSubMenu [get]
 
virtual bool UseSubMenuSlider [get]
 
virtual bool SubMenuAsGroup [get]
 
virtual int SubMenuModeIndex [get]
 
virtual bool ShowExtraHint [get]
 
BaseTileSelector tileSelector [get]
 
- Properties inherited from EClass
static Game game [get]
 
static bool AdvMode [get]
 
static Player player [get]
 
static Chara pc [get]
 
static UI ui [get]
 
static Map _map [get]
 
static Zone _zone [get]
 
static FactionBranch Branch [get]
 
static FactionBranch BranchOrHomeBranch [get]
 
static Faction Home [get]
 
static Faction Wilds [get]
 
static Scene scene [get]
 
static BaseGameScreen screen [get]
 
static GameSetting setting [get]
 
static GameData gamedata [get]
 
static ColorProfile Colors [get]
 
static World world [get]
 
static SourceManager sources [get]
 
static SourceManager editorSources [get]
 
static SoundManager Sound [get]
 
static CoreDebug debug [get]
 

Private Attributes

float gearAngle
 
Vector3 lastCamPos
 
bool startedRun
 

Additional Inherited Members

- Static Public Member Functions inherited from ActionMode
static void OnGameInstantiated ()
 
- Static Public Member Functions inherited from EClass
static int rnd (int a)
 
static int curve (int a, int start, int step, int rate=75)
 
static int rndHalf (int a)
 
static float rndf (float a)
 
static int rndSqrt (int a)
 
static void Wait (float a, Card c)
 
static void Wait (float a, Point p)
 
static int Bigger (int a, int b)
 
static int Smaller (int a, int b)
 
- Static Protected Attributes inherited from ActionMode
static Vector3 mpos
 

Detailed Description

Definition at line 5 of file AM_Adv.cs.

Member Function Documentation

◆ _OnUpdateInput()

override void AM_Adv._OnUpdateInput ( )
inlinevirtual

Reimplemented from AM_BaseGameMode.

Reimplemented in AM_ADV_Target.

Definition at line 474 of file AM_Adv.cs.

475 {
476 if (EClass.debug.enable)
477 {
478 EClass.player.flags.debugEnabled = true;
479 }
481 {
482 EClass.game.Save(isAutoSave: true);
483 EClass.player.willAutoSave = false;
484 }
486 {
487 RecipeUpdater.dirty = false;
489 }
491 {
492 actCount = 0;
493 }
495 {
497 {
498 rightMouseTimer = 2.5f;
499 }
500 }
501 else
502 {
504 }
505 EClass.player.waitingInput = false;
507 {
509 {
510 Msg.Say("abort_lowHP");
511 EClass.pc.ai.Cancel();
512 }
514 {
515 Msg.Say("abort_allyDying");
516 EClass.pc.ai.Cancel();
517 }
519 {
520 Msg.Say("abort_itemLoss");
521 EClass.pc.ai.Cancel();
522 }
523 }
524 itemLost = 0;
525 if (EClass.pc.HasNoGoal)
526 {
528 {
530 EClass.player.invlunerable = false;
531 return;
532 }
534 {
535 EClass.player.lastTurn = EClass.pc.turn;
536 EClass.player.invlunerable = false;
537 EClass.pc.RemoveCondition<ConInvulnerable>();
539 if (!EClass.pc.HasNoGoal)
540 {
541 return;
542 }
543 }
544 EClass.player.waitingInput = true;
546 {
547 Thing playingTool = AI_PlayMusic.playingTool;
548 if (EInput.IsAnyKeyDown() || (playingTool.GetRootCard() != EClass.pc && (!playingTool.ExistsOnMap || playingTool.Dist(EClass.pc) > 1)))
549 {
551 return;
552 }
553 UISong instance = UISong.Instance;
554 if (!instance || instance.ratio > 0.85f)
555 {
557 {
558 tool = playingTool
559 });
560 return;
561 }
562 }
563 }
565 {
566 EClass.player.returnInfo.askDest = false;
567 int uidDest = 0;
568 List<Zone> list = EClass.game.spatials.ListReturnLocations();
569 if (list == null || list.Count == 0)
570 {
571 EClass.player.returnInfo = null;
572 Msg.Say("returnAbort");
573 return;
574 }
575 EClass.ui.AddLayer<LayerList>().SetList2(list, (Zone a) => a.NameWithDangerLevel, delegate(Zone a, ItemGeneral b)
576 {
577 uidDest = a.uid;
578 if (a is Zone_Dungeon)
579 {
580 uidDest = a.FindDeepestZone().uid;
581 }
582 EClass.player.returnInfo = new Player.ReturnInfo
583 {
584 turns = EClass.rnd(10) + 10,
585 uidDest = uidDest
586 };
588 {
589 EClass.player.returnInfo.turns = 1;
591 }
592 }, delegate(Zone a, ItemGeneral b)
593 {
594 string lang = ((a is Zone_Dungeon) ? a.TextDeepestLv : "surface".lang());
595 b.SetSubText(lang, 200, FontColor.Default, TextAnchor.MiddleRight);
596 b.Build();
597 b.button1.mainText.rectTransform.sizeDelta = new Vector2(350f, 20f);
598 }).SetSize(500f)
599 .SetOnKill(delegate
600 {
601 if (uidDest == 0)
602 {
603 EClass.player.returnInfo = null;
604 Msg.Say("returnAbort");
605 }
606 })
607 .SetTitles("wReturn");
608 return;
609 }
611 {
612 EClass.player.haltMove = false;
613 TryCancelInteraction(sound: false);
614 EInput.Consume(1);
615 return;
616 }
618 {
619 keepWalking = false;
620 EInput.Consume(1);
621 return;
622 }
623 if (EClass.player.showShippingResult && !EClass.ui.IsActive)
624 {
625 EClass.player.showShippingResult = false;
626 EClass.ui.AddLayer<LayerShippingResult>().Show();
627 }
629 {
630 pressedAction.timer += Core.delta;
631 if (pressedAction.action != null)
632 {
633 if (pressedAction.canTurbo && ((autorun && pressedAction.timer > 0.45f) || Input.GetKey(KeyCode.LeftShift)))
634 {
635 SetTurbo();
636 }
638 {
639 return;
640 }
642 {
643 pressedAction.timerRepeat += Core.delta;
644 if (pressedAction.timerRepeat < 0.3f)
645 {
646 return;
647 }
648 }
650 if (pressedAction.action())
651 {
653 {
654 EClass.player.EndTurn(consume: false);
656 {
657 pressedAction.action = null;
658 }
659 }
660 }
661 else if (!pressedAction.repeat)
662 {
663 pressedAction.action = null;
664 }
665 }
666 else if ((autorun && pressedAction.timer > 0.5f) || Input.GetKey(KeyCode.LeftShift))
667 {
668 SetTurbo();
669 }
670 return;
671 }
673 {
674 updatePlans = true;
675 }
676 cursorMove = false;
677 EClass.player.nextMove = Vector2.zero;
678 if (EClass.pc.HasNoGoal)
679 {
680 EndTurbo();
681 }
682 pressedAction.button = null;
683 pressedAction.axis = Vector2.zero;
684 pressedAction.count = 0;
685 pressedAction.timerRepeat = 0f;
687 {
688 EClass.player.willEndTurn = false;
690 return;
691 }
692 if (EInput.axis != Vector2.zero)
693 {
694 AxisMove();
695 return;
696 }
698 startedRun = false;
700 {
701 EClass.pc.ai.Cancel();
702 }
703 movedByKey = false;
706 {
708 {
709 return;
710 }
711 CursorSystem.ignoreCount = 5;
713 }
715 {
717 {
718 return;
719 }
720 CursorSystem.ignoreCount = 5;
722 }
724 {
726 {
727 if (EInput.wheel != 0)
728 {
730 SE.Tab();
732 EInput.wheel = 0;
733 }
735 {
736 EInput.middleMouse.pressedTimer = 100f;
737 }
738 }
739 else if (EClass.scene.mouseTarget.CanCycle())
740 {
741 if (EInput.wheel != 0)
742 {
744 EInput.wheel = 0;
745 }
747 {
748 EInput.middleMouse.pressedTimer = 100f;
749 }
750 }
751 }
753 {
755 {
757 {
759 SE.Rotate();
760 }
761 else
762 {
763 DoFunc(input.middleClick);
764 }
765 }
767 {
768 DoFunc(input.middlePressLong);
769 }
770 }
772 {
773 DoFunc(input.mouse3Click);
774 }
775 else if (EInput.mouse3.pressedLong)
776 {
777 DoFunc(input.mouse3PressLong);
778 }
780 {
781 if (zoomOut)
782 {
783 ToggleZoom();
784 }
785 else
786 {
787 DoFunc(input.mouse4Click);
788 }
789 }
790 else if (EInput.mouse4.pressedLong)
791 {
792 DoFunc(input.mouse4PressLong);
793 }
794 if (EInput.wheel != 0)
795 {
797 {
798 if (EInput.wheel != 0)
799 {
801 SE.Tab();
803 EInput.wheel = 0;
804 }
805 }
806 else
807 {
809 UpdatePlans();
810 }
811 }
813 {
815 }
816 if (Input.GetKey(KeyCode.LeftControl))
817 {
818 if (Input.GetKeyDown(KeyCode.F))
819 {
820 EClass.ui.widgets.Toggle("Search")?.SoundActivate();
821 }
822 return;
823 }
824 switch (EInput.action)
825 {
826 case EAction.Search:
827 EClass.ui.widgets.Toggle("Search")?.SoundActivate();
828 break;
829 case EAction.Meditate:
830 if (EClass.pc.HasNoGoal)
831 {
832 EClass.pc.UseAbility("AI_Meditate", EClass.pc);
833 }
834 break;
835 case EAction.Dump:
837 break;
838 case EAction.EmptyHand:
839 if ((bool)WidgetCurrentTool.Instance)
840 {
842 }
843 break;
844 case EAction.AutoCombat:
845 {
847 {
848 break;
849 }
850 List<Chara> list2 = EClass.scene.mouseTarget.pos.ListCharas();
851 list2.Sort((Chara a, Chara b) => a.hostility - b.hostility);
852 foreach (Chara item in list2)
853 {
854 if (item.hostility < Hostility.Friend)
855 {
857 return;
858 }
859 }
860 Msg.Say("noTargetFound");
861 break;
862 }
863 case EAction.QuickSave:
865 {
866 if (!EClass.pc.HasNoGoal)
867 {
868 SE.Beep();
869 }
870 else
871 {
872 EClass.game.Save();
873 }
874 }
875 break;
876 case EAction.QuickLoad:
877 {
879 {
880 SE.Beep();
881 break;
882 }
883 string slot = Game.id;
884 bool isCloud = EClass.game.isCloud;
885 Game.TryLoad(slot, isCloud, delegate
886 {
888 {
889 EClass.scene.Init(Scene.Mode.None);
890 Game.Load(slot, isCloud);
891 });
892 });
893 break;
894 }
895 case EAction.Report:
896 if (!EClass.debug.enable)
897 {
898 EClass.ui.ToggleFeedback();
899 }
900 break;
901 case EAction.Wait:
902 {
904 {
906 break;
907 }
908 if (!EClass.pc.HasNoGoal)
909 {
911 {
912 EClass.pc.ai.Cancel();
913 }
914 break;
915 }
917 {
919 break;
920 }
922 if (traitNewZone != null && traitNewZone.CanAutoEnter())
923 {
924 traitNewZone.MoveZone();
926 }
927 else
928 {
931 }
932 break;
933 }
934 case EAction.Fire:
936 {
939 {
940 SE.Play("lock_on");
941 }
943 {
945 }
946 }
947 else
948 {
949 if (!EClass.pc.HasNoGoal)
950 {
951 break;
952 }
954 bool reloading = EClass.pc.HasCondition<ConReload>();
955 if (thing == null || !thing.CanAutoFire(EClass.pc, EClass.player.target, reloading))
956 {
958 {
959 if (button.obj is Thing thing2 && thing2.CanAutoFire(EClass.pc, EClass.player.target, reloading))
960 {
961 thing = thing2;
962 break;
963 }
964 }
965 }
966 if (thing == null || !thing.CanAutoFire(EClass.pc, EClass.player.target, reloading))
967 {
968 thing = EClass.pc.things.Find((Thing _t) => _t.isEquipped && _t.CanAutoFire(EClass.pc, EClass.player.target, reloading));
969 }
970 if (thing == null || !thing.CanAutoFire(EClass.pc, EClass.player.target, reloading))
971 {
972 break;
973 }
974 if (thing.HasTag(CTAG.throwWeapon))
975 {
978 {
979 ACT.Throw.target = thing;
981 EClass.player.EndTurn(consume: false);
982 SetTurbo();
983 }
984 }
985 else if (thing.trait is TraitAbility traitAbility)
986 {
987 if (traitAbility.act.CanPerform(EClass.pc, EClass.player.target, EClass.player.target.pos) && EClass.pc.UseAbility(traitAbility.act.source.alias, EClass.player.target, EClass.player.target.pos))
988 {
989 EClass.player.EndTurn(consume: false);
990 }
991 }
992 else
993 {
994 if (!(thing.trait is TraitToolRange))
995 {
996 break;
997 }
998 EClass.pc.ranged = thing;
1000 {
1001 EClass.player.renderThing = thing;
1003 {
1004 EClass.player.EndTurn(consume: false);
1005 SetTurbo();
1006 }
1007 }
1008 }
1009 }
1010 break;
1011 }
1012 }
CTAG
Definition: CTAG.cs:2
EAction
Definition: EAction.cs:2
FontColor
Definition: FontColor.cs:2
Hostility
Definition: Hostility.cs:2
Definition: ACT.cs:6
static ActRanged Ranged
Definition: ACT.cs:17
static ActThrow Throw
Definition: ACT.cs:19
static new ActWait Wait
Definition: ACT.cs:7
virtual bool CanManualCancel()
Definition: AIAct.cs:312
virtual bool IsRunning
Definition: AIAct.cs:31
virtual Status Cancel()
Definition: AIAct.cs:291
static Thing playingTool
Definition: AI_PlayMusic.cs:10
static bool keepPlaying
Definition: AI_PlayMusic.cs:8
static void CancelKeepPlaying()
Definition: AI_PlayMusic.cs:40
Func< bool > action
Definition: AM_Adv.cs:23
ButtonState button
Definition: AM_Adv.cs:9
bool IsPressing()
Definition: AM_Adv.cs:81
void AxisMove()
Definition: AM_Adv.cs:1092
float timerStartRunning
Definition: AM_Adv.cs:113
void ToggleZoom()
Definition: AM_Adv.cs:1060
bool cursorMove
Definition: AM_Adv.cs:115
void EndTurbo()
Definition: AM_Adv.cs:1055
bool zoomOut
Definition: AM_Adv.cs:103
bool TryCancelInteraction(bool sound=true)
Definition: AM_Adv.cs:1069
static int actCount
Definition: AM_Adv.cs:101
bool autorun
Definition: AM_Adv.cs:172
void OnBecomeNoGoal()
Definition: AM_Adv.cs:443
float rightMouseTimer
Definition: AM_Adv.cs:164
bool startedRun
Definition: AM_Adv.cs:166
ActPlan planLeft
Definition: AM_Adv.cs:132
void UpdatePlans()
Definition: AM_Adv.cs:410
void SetPressedAction(ButtonState button)
Definition: AM_Adv.cs:1158
bool keepWalking
Definition: AM_Adv.cs:117
bool CanAct()
Definition: AM_Adv.cs:1087
int itemLost
Definition: AM_Adv.cs:109
PressedAction pressedAction
Definition: AM_Adv.cs:125
bool updatePlans
Definition: AM_Adv.cs:158
void SetTurbo(int mtp=-1)
Definition: AM_Adv.cs:1040
bool movedByKey
Definition: AM_Adv.cs:107
void ModAltitude(int a)
Definition: AM_Build.cs:366
Point pos
Definition: ActPlan.cs:149
override bool Perform()
Definition: ActRanged.cs:65
override bool CanPerform()
Definition: ActRanged.cs:44
override bool Perform()
Definition: ActThrow.cs:38
static bool CanThrow(Chara c, Thing t, Card target, Point p=null)
Definition: ActThrow.cs:60
override bool Perform()
Definition: ActWait.cs:7
static AM_Build Build
Definition: ActionMode.cs:49
void DoFunc(CoreConfig.GameFuncBuild func)
Definition: ActionMode.cs:1033
void WaitForEndOfFrame(Action action)
Definition: BaseCore.cs:61
bool pressing
Definition: ButtonState.cs:35
bool clicked
Definition: ButtonState.cs:37
float pressedTimer
Definition: ButtonState.cs:17
float clickDuration
Definition: ButtonState.cs:23
bool pressedLong
Definition: ButtonState.cs:64
int hp
Definition: Card.cs:226
bool ExistsOnMap
Definition: Card.cs:1961
bool HasTag(CTAG tag)
Definition: Card.cs:2455
Point pos
Definition: Card.cs:55
Trait trait
Definition: Card.cs:49
ThingContainer things
Definition: Card.cs:34
int turn
Definition: Card.cs:61
Card GetRootCard()
Definition: Card.cs:3173
int Evalue(int ele)
Definition: Card.cs:2431
int Dist(Card c)
Definition: Card.cs:6777
Definition: Chara.cs:10
bool UseAbility(string idAct, Card tc=null, Point pos=null, bool pt=false)
Definition: Chara.cs:5228
AIAct ai
Definition: Chara.cs:187
bool IsCriticallyWounded(bool includeRide=false)
Definition: Chara.cs:986
Party party
Definition: Chara.cs:43
bool HasCondition(string alias)
Definition: Chara.cs:8568
void SetAIImmediate(AIAct g)
Definition: Chara.cs:8077
Stats mana
Definition: Chara.cs:963
bool HasNoGoal
Definition: Chara.cs:821
Hostility hostility
Definition: Chara.cs:276
override void LookAt(Card c)
Definition: Chara.cs:3219
bool WillConsumeTurn()
Definition: Chara.cs:3343
InputSetting input
Definition: CoreConfig.cs:602
bool instaReturn
Definition: CoreDebug.cs:204
bool enable
Definition: CoreDebug.cs:285
bool boradcast
Definition: CoreDebug.cs:259
void BroadcastNext()
Definition: CoreDebug.cs:2276
Definition: Core.cs:14
static float delta
Definition: Core.cs:17
CoreConfig config
Definition: Core.cs:70
Definition: EClass.cs:5
static Game game
Definition: EClass.cs:8
static Scene scene
Definition: EClass.cs:30
static int rnd(int a)
Definition: EClass.cs:50
static Core core
Definition: EClass.cs:6
static Zone _zone
Definition: EClass.cs:20
static Player player
Definition: EClass.cs:12
static Chara pc
Definition: EClass.cs:14
static CoreDebug debug
Definition: EClass.cs:48
static UI ui
Definition: EClass.cs:16
Definition: EInput.cs:8
static bool IsAnyKeyDown(bool includeAxis=true, bool _skipframe=true)
Definition: EInput.cs:619
static void WaitReleaseKey()
Definition: EInput.cs:650
static int wheel
Definition: EInput.cs:289
static ButtonState middleMouse
Definition: EInput.cs:353
static bool hasShiftChanged
Definition: EInput.cs:273
static void Consume(int _skipFrame)
Definition: EInput.cs:656
static ButtonState mouse4
Definition: EInput.cs:357
static Vector2 axis
Definition: EInput.cs:331
static ButtonState leftMouse
Definition: EInput.cs:349
static bool isShiftDown
Definition: EInput.cs:261
static ButtonState rightMouse
Definition: EInput.cs:351
static ButtonState mouse3
Definition: EInput.cs:355
static KeyboardPress keyFire
Definition: EInput.cs:249
static EAction action
Definition: EInput.cs:259
bool disableManualSave
RecipeUpdater recipe
Definition: GameUpdater.cs:363
ConfigAutoCombat autoCombat
Definition: Game.cs:93
Definition: Game.cs:8
static void Load(string id, bool cloud)
Definition: Game.cs:313
GamePrincipal principal
Definition: Game.cs:221
static bool TryLoad(string id, bool cloud, Action onLoad)
Definition: Game.cs:302
static string id
Definition: Game.cs:147
bool Save(bool isAutoSave=false, bool silent=false)
Definition: Game.cs:960
SpatialManager spatials
Definition: Game.cs:152
bool isCloud
Definition: Game.cs:239
GameUpdater updater
Definition: Game.cs:243
Config config
Definition: Game.cs:215
static bool CanRotate()
Definition: HotItemHeld.cs:28
static bool CanChangeHeightByWheel()
Definition: HotItemHeld.cs:15
static TaskBuild taskBuild
Definition: HotItemHeld.cs:7
virtual bool LookAtMouse
Definition: HotItem.cs:44
virtual Thing Thing
Definition: HotItem.cs:38
void Build()
Definition: ItemGeneral.cs:161
UIButton SetSubText(string lang, int x, FontColor c=FontColor.Default, TextAnchor align=TextAnchor.MiddleLeft)
Definition: ItemGeneral.cs:119
Layer SetOnKill(Action action)
Definition: Layer.cs:579
Definition: Msg.cs:5
static string Say(string idLang, string ref1, string ref2=null, string ref3=null, string ref4=null)
Definition: Msg.cs:58
bool IsCriticallyWounded(bool includePc=false)
Definition: Party.cs:138
bool showShippingResult
Definition: Player.cs:793
bool haltMove
Definition: Player.cs:972
bool HasValidRangedTarget()
Definition: Player.cs:2072
bool willAutoSave
Definition: Player.cs:976
void EndTurn(bool consume=true)
Definition: Player.cs:1866
void EnterLocalZone(bool encounter=false, Chara mob=null)
Definition: Player.cs:1736
int autoCombatStartHP
Definition: Player.cs:1024
bool TargetRanged()
Definition: Player.cs:2081
Chara target
Definition: Player.cs:1032
HotItem currentHotItem
Definition: Player.cs:901
ReturnInfo returnInfo
Definition: Player.cs:673
int lastTurn
Definition: Player.cs:992
bool willEndTurn
Definition: Player.cs:962
bool CanAcceptInput()
Definition: Player.cs:2212
void CycleTarget(int a)
Definition: PointTarget.cs:204
bool isValid
Definition: PointTarget.cs:30
bool CanCycle()
Definition: PointTarget.cs:215
List< Chara > ListCharas()
Definition: Point.cs:1135
int Distance(Point p)
Definition: Point.cs:953
Thing FindThing(Func< Thing, bool > func)
Definition: Point.cs:1104
static bool dirty
void Build(Point _p, Mode _mode=Mode.Passive)
virtual void Rotate()
Definition: Recipe.cs:825
Definition: Scene.cs:8
PointTarget mouseTarget
Definition: Scene.cs:129
void Init(Mode newMode)
Definition: Scene.cs:172
Mode
Definition: Scene.cs:10
List< Zone > ListReturnLocations()
int uid
Definition: Spatial.cs:70
virtual bool IsRegion
Definition: Spatial.cs:501
Zone FindDeepestZone()
Definition: Spatial.cs:701
virtual int value
Definition: Stats.cs:56
Recipe recipe
Definition: TaskBuild.cs:8
static void TryPerform()
Definition: TaskDump.cs:6
bool isRepeated
Definition: TaskPoint.cs:13
Thing Find(int uid)
Definition: Thing.cs:8
bool CanAutoFire(Chara c, Card tg, bool reloading=false)
Definition: Thing.cs:108
bool CanAutoEnter()
bool MoveZone(bool confirmed=false)
Definition: UIList.cs:9
List< ButtonPair > buttons
Definition: UIList.cs:244
Definition: UISong.cs:5
static UISong Instance
Definition: UISong.cs:6
float ratio
Definition: UISong.cs:18
static WidgetCurrentTool Instance
void Select(int index, bool fromHotkey=false)
UIPlaceHelper placer
Definition: Zone.cs:12
string TextDeepestLv
Definition: Zone.cs:425

References EClass._zone, ConfigAutoCombat.abortOnAllyDying, ConfigAutoCombat.abortOnHalfHP, ConfigAutoCombat.abortOnItemLoss, actCount, AM_Adv.PressedAction.action, EInput.action, Chara.ai, Player.ReturnInfo.askDest, Game.Config.autoCombat, Player.autoCombatStartHP, autorun, EInput.axis, AxisMove(), CoreDebug.boradcast, CoreDebug.BroadcastNext(), ActionMode.Build, ItemGeneral.Build(), RecipeUpdater.Build(), AM_Adv.PressedAction.button, UIList.buttons, Player.CanAcceptInput(), CanAct(), TraitNewZone.CanAutoEnter(), Thing.CanAutoFire(), AIAct.Cancel(), AI_PlayMusic.CancelKeepPlaying(), HotItemHeld.CanChangeHeightByWheel(), PointTarget.CanCycle(), AIAct.CanManualCancel(), ActRanged.CanPerform(), HotItemHeld.CanRotate(), ActThrow.CanThrow(), AM_Adv.PressedAction.canTurbo, ButtonState.clickDuration, ButtonState.clicked, Core.config, Game.config, EInput.KeyboardPress.Consume(), EInput.Consume(), EClass.core, AM_Adv.PressedAction.count, Player.currentHotItem, cursorMove, PointTarget.CycleTarget(), EClass.debug, Core.delta, RecipeUpdater.dirty, GamePrincipal.disableManualSave, Card.Dist(), Point.Distance(), ActionMode.DoFunc(), ButtonState.down, CoreDebug.enable, EndTurbo(), Player.EndTurn(), Player.EnterLocalZone(), Card.Evalue(), Card.ExistsOnMap, ThingContainer.Find(), Spatial.FindDeepestZone(), Point.FindThing(), EClass.game, Card.GetRootCard(), Player.haltMove, Chara.HasCondition(), Chara.HasNoGoal, EInput.hasShiftChanged, Card.HasTag(), Player.HasValidRangedTarget(), Chara.hostility, Card.hp, Game.id, AM_Adv.PressedAction.ignoreCount, Scene.Init(), CoreConfig.input, UISong.Instance, WidgetCurrentTool.Instance, CoreDebug.instaReturn, EInput.IsAnyKeyDown(), Game.isCloud, Party.IsCriticallyWounded(), Chara.IsCriticallyWounded(), AM_Adv.PressedAction.IsPressing(), Spatial.IsRegion, TaskPoint.isRepeated, EInput.KeyboardPress.IsRepeating, AIAct.IsRunning, EInput.isShiftDown, PointTarget.isValid, item, itemLost, AI_PlayMusic.keepPlaying, keepWalking, EInput.keyFire, Player.lastTurn, EInput.leftMouse, WidgetCurrentTool.list, Point.ListCharas(), SpatialManager.ListReturnLocations(), Game.Load(), Chara.LookAt(), HotItem.LookAtMouse, Chara.mana, CoreConfig.InputSetting.middleClick, EInput.middleMouse, CoreConfig.InputSetting.middlePressLong, AM_Build.ModAltitude(), WidgetCurrentTool.ModSelected(), EInput.mouse3, CoreConfig.InputSetting.mouse3Click, CoreConfig.InputSetting.mouse3PressLong, EInput.mouse4, CoreConfig.InputSetting.mouse4Click, CoreConfig.InputSetting.mouse4PressLong, Scene.mouseTarget, movedByKey, TraitNewZone.MoveZone(), Spatial.NameWithDangerLevel, OnBecomeNoGoal(), Chara.party, EClass.pc, ActRanged.Perform(), ActThrow.Perform(), ActWait.Perform(), WidgetCurrentTool.placer, planLeft, EClass.player, AI_PlayMusic.playingTool, ActPlan.pos, Card.pos, PointTarget.pos, pressedAction, ButtonState.pressedLong, ButtonState.pressedTimer, ButtonState.pressing, Game.principal, ACT.Ranged, UISong.ratio, GameUpdater.recipe, TaskBuild.recipe, UIPlaceHelper.Refresh(), AM_Adv.PressedAction.repeat, Player.returnInfo, EInput.rightMouse, rightMouseTimer, EClass.rnd(), Recipe.Rotate(), Game.Save(), Msg.Say(), EClass.scene, WidgetCurrentTool.Select(), Chara.SetAIImmediate(), Layer.SetOnKill(), SetPressedAction(), ItemGeneral.SetSubText(), SetTurbo(), Player.showShippingResult, Game.spatials, startedRun, Player.target, Player.TargetRanged(), HotItemHeld.taskBuild, Zone.TextDeepestLv, HotItem.Thing, Card.things, ACT.Throw, AM_Adv.PressedAction.timer, AM_Adv.PressedAction.timerRepeat, timerStartRunning, ToggleZoom(), tool, Card.trait, TryCancelInteraction(), Game.TryLoad(), TaskDump.TryPerform(), Card.turn, EClass.ui, Spatial.uid, updatePlans, UpdatePlans(), Game.updater, Chara.UseAbility(), Stats.value, ACT.Wait, BaseCore.WaitForEndOfFrame(), AM_Adv.PressedAction.waitForTurn, EInput.WaitReleaseKey(), EInput.wheel, Player.willAutoSave, Chara.WillConsumeTurn(), AM_Adv.PressedAction.willEndTurn, Player.willEndTurn, and zoomOut.

◆ AxisMove()

void AM_Adv.AxisMove ( )
inline

Definition at line 1092 of file AM_Adv.cs.

1093 {
1094 Vector2 vector = ((EClass.core.config.input.altKeyAxis && !EClass._zone.IsRegion) ? Util.ConvertAxis(EInput.axis) : EInput.axis);
1095 if (!startedRun)
1096 {
1097 if ((autorun && timerStartRunning >= 0.7f) || Input.GetKey(KeyCode.LeftShift))
1098 {
1099 SetTurbo();
1100 startedRun = true;
1101 }
1102 }
1103 else if (Input.GetKeyDown(KeyCode.LeftShift))
1104 {
1105 SetTurbo((turbo == 0f) ? (-1) : 0);
1106 }
1108 {
1109 SetTurbo((!Input.GetKey(KeyCode.LeftShift)) ? (-1) : 0);
1110 }
1112 EClass.player.nextMove.x = 0f;
1113 EClass.player.nextMove.y = 0f;
1114 Point point = EClass.pc.pos.Copy();
1115 point.x += (int)vector.x;
1116 point.z += (int)vector.y;
1117 if (EClass.pc.HasNoGoal && !point.IsValid && EClass.player.CanExitBorder(point))
1118 {
1120 return;
1121 }
1122 axisTarget.Update(point);
1123 pressedAction.Init(Vector3.zero);
1125 if (planKeyboard.HasAct)
1126 {
1127 if (planKeyboard.list[0].act.ResetAxis && EClass.pc.ai is GoalManualMove)
1128 {
1129 EInput.forbidAxis = EInput.axis;
1130 EClass.pc.ai.Cancel();
1131 }
1132 else
1133 {
1134 pressedAction.axis = EInput.axis;
1136 }
1137 return;
1138 }
1139 EClass.player.nextMove.x = vector.x;
1140 EClass.player.nextMove.y = vector.y;
1141 if (!(EClass.pc.ai is GoalManualMove) && EClass.pc.HasNoGoal && GoalManualMove.CanMove())
1142 {
1143 SetManualMove();
1144 }
1145 movedByKey = true;
1146 }
void SetAction(Func< bool > _action=null, bool _canTurbo=true, bool _willEndTurn=true, bool _waitForTurn=true, bool _canRepeat=false)
Definition: AM_Adv.cs:55
void Init(Vector3 _axis)
Definition: AM_Adv.cs:37
static float turbo
Definition: AM_Adv.cs:99
void SetManualMove()
Definition: AM_Adv.cs:1148
ActPlan planKeyboard
Definition: AM_Adv.cs:142
PointTarget axisTarget
Definition: AM_Adv.cs:127
void Update(PointTarget target)
Definition: ActPlan.cs:411
Func< bool > GetAction()
Definition: ActPlan.cs:286
List list
Definition: ActPlan.cs:163
bool WillEndTurn
Definition: ActPlan.cs:220
bool canRepeat
Definition: ActPlan.cs:190
bool HasAct
Definition: ActPlan.cs:243
static bool CanMove()
bool CanExitBorder(Point p)
Definition: Player.cs:1679
void ExitBorder(ActPlan p=null)
Definition: Player.cs:1637
void Update(Point _pos)
Definition: PointTarget.cs:52
Definition: Point.cs:9
Point Copy()
Definition: Point.cs:467
int x
Definition: Point.cs:36
int z
Definition: Point.cs:39
bool IsValid
Definition: Point.cs:88
Definition: Util.cs:10
static Vector2 ConvertAxis(Vector2 v)
Definition: Util.cs:157

References EClass._zone, Chara.ai, CoreConfig.Test.alwaysRun, autorun, EInput.axis, axisTarget, AIAct.Cancel(), Player.CanExitBorder(), GoalManualMove.CanMove(), ActPlan.canRepeat, Core.config, Point.Copy(), EClass.core, Core.delta, Player.ExitBorder(), ActPlan.GetAction(), ActPlan.HasAct, Chara.HasNoGoal, AM_Adv.PressedAction.Init(), Spatial.IsRegion, Point.IsValid, ActPlan.list, movedByKey, EClass.pc, planKeyboard, EClass.player, Card.pos, pressedAction, AM_Adv.PressedAction.SetAction(), SetManualMove(), SetTurbo(), startedRun, CoreConfig.test, timerStartRunning, turbo, PointTarget.Update(), ActPlan.Update(), Util, ActPlan.WillEndTurn, Point.x, and Point.z.

Referenced by _OnUpdateInput().

◆ CanAct()

bool AM_Adv.CanAct ( )
inline

Definition at line 1087 of file AM_Adv.cs.

1088 {
1089 return EClass.pc.HasNoGoal;
1090 }

References Chara.HasNoGoal, and EClass.pc.

Referenced by _OnUpdateInput().

◆ ClearPlans()

void AM_Adv.ClearPlans ( )
inline

Definition at line 436 of file AM_Adv.cs.

437 {
438 planLeft.Clear();
440 updatePlans = true;
441 }
ActPlan planRight
Definition: AM_Adv.cs:137
void Clear()
Definition: ActPlan.cs:405

References ActPlan.Clear(), planLeft, planRight, and updatePlans.

Referenced by Chara.Kick(), and ToggleZoom().

◆ EndTurbo()

void AM_Adv.EndTurbo ( )
inline

Definition at line 1055 of file AM_Adv.cs.

1056 {
1057 turbo = 0f;
1058 }

References turbo.

Referenced by _OnUpdateInput(), OnDeactivate(), and PressedActionMove().

◆ GetDefaultTile()

override int AM_Adv.GetDefaultTile ( Point  p)
inlinevirtual

Reimplemented from ActionMode.

Definition at line 318 of file AM_Adv.cs.

319 {
320 if (!p.IsSync)
321 {
322 return 30;
323 }
324 return 0;
325 }
bool IsSync
Definition: Point.cs:320

References Point.IsSync.

◆ HighlightWall()

override bool AM_Adv.HighlightWall ( Point  p)
inlinevirtual

Reimplemented from ActionMode.

Definition at line 252 of file AM_Adv.cs.

253 {
254 if (EClass.pc.held != null)
255 {
256 return TaskMine.CanMine(p, EClass.pc.held);
257 }
258 return false;
259 }
Card held
Definition: Chara.cs:67
static bool CanMine(Point pos, Card t)
Definition: TaskMine.cs:31

References TaskMine.CanMine(), Chara.held, and EClass.pc.

◆ OnActivate()

override void AM_Adv.OnActivate ( )
inlinevirtual

Reimplemented from ActionMode.

Reimplemented in AM_ADV_Target.

Definition at line 261 of file AM_Adv.cs.

262 {
263 if ((bool)WidgetMouseover.Instance)
264 {
266 }
267 ActionMode.DefaultMode = this;
269 EClass.pc.ai.Cancel();
271 (EClass.pc.renderer as CharaRenderer).first = true;
275 }
BaseTileMap tileMap
virtual void RefreshPosition()
void RefreshHeight()
Definition: BaseTileMap.cs:888
virtual void SetFirst(bool first, Vector3 pos)
CardRenderer renderer
Definition: Card.cs:57
static BaseGameScreen screen
Definition: EClass.cs:32
ref Vector3 PositionCenter()
Definition: Point.cs:563
void Hide(bool immediate=false)
static WidgetMouseover Instance

References Chara.ai, AIAct.Cancel(), BaseGameScreen.FocusPC(), WidgetMouseover.Hide(), AM_Adv.PressedAction.Init(), WidgetMouseover.Instance, EClass.pc, Card.pos, Point.PositionCenter(), pressedAction, BaseTileMap.RefreshHeight(), BaseGameScreen.RefreshPosition(), Card.renderer, EClass.screen, CardRenderer.SetFirst(), and BaseGameScreen.tileMap.

◆ OnAfterUpdate()

override void AM_Adv.OnAfterUpdate ( )
inlinevirtual

Reimplemented from ActionMode.

Definition at line 339 of file AM_Adv.cs.

340 {
341 Vector3 position = (mouseTarget.pos.IsValid ? mouseTarget.pos.PositionAuto() : EClass.pc.pos.PositionAuto());
342 position = Camera.main.WorldToScreenPoint(position);
343 position.z = 0f;
344 position += EClass.ui.hud.transRightPos * Mathf.Min(0f, EClass.screen.Zoom - 1f);
345 EClass.ui.hud.transRight.position = position;
347 }
PointTarget mouseTarget
Definition: AM_Adv.cs:170
void MarkMapHighlights()
Definition: Player.cs:2206
ref Vector3 PositionAuto()
Definition: Point.cs:515

References Player.MarkMapHighlights(), mouseTarget, EClass.pc, EClass.player, Card.pos, PointTarget.pos, Point.PositionAuto(), EClass.screen, and BaseGameScreen.Zoom.

◆ OnBecomeNoGoal()

void AM_Adv.OnBecomeNoGoal ( )
inline

Definition at line 443 of file AM_Adv.cs.

444 {
445 EClass.player.renderThing = null;
446 if (EClass.player.hotItemToRestore != null)
447 {
449 {
451 }
452 EClass.player.hotItemToRestore = null;
453 }
455 {
457 }
458 if (EClass.rnd(30) == 0 && EClass.pc.HasElement(1559))
459 {
460 List<Thing> list = EClass.pc.things.List((Thing a) => a.trait is TraitPotion, onlyAccessible: true);
461 if (list.Count > 0)
462 {
463 EClass.pc.Drink(list.RandomItem());
465 }
466 }
467 if ((int)(Time.timeSinceLevelLoad / 60f / 60f) > Player.realHour)
468 {
470 }
472 }
bool HasElement(int ele, int req=1)
Definition: Card.cs:5214
void Drink(Card t)
Definition: Chara.cs:4612
new GameConfig game
Definition: CoreConfig.cs:596
Definition: Player.cs:11
void OnAdvanceRealHour()
Definition: Player.cs:1312
static int realHour
Definition: Player.cs:938
HotItem hotItemToRestore
Definition: Player.cs:950
void SetCurrentHotItem(HotItem item)
Definition: Player.cs:2046
List< Thing > List(Func< Thing, bool > func, bool onlyAccessible=false)
static void TryPlayReserve()
Definition: Tutorial.cs:68

References CoreConfig.GameConfig.alwaysUpdateRecipe, RecipeUpdater.Build(), Core.config, EClass.core, Player.currentHotItem, Chara.Drink(), Player.EndTurn(), CoreConfig.game, EClass.game, Card.HasElement(), Player.hotItemToRestore, ThingContainer.List(), Player.OnAdvanceRealHour(), EClass.pc, EClass.player, Card.pos, Player.realHour, GameUpdater.recipe, EClass.rnd(), Player.SetCurrentHotItem(), Card.things, Card.trait, Tutorial.TryPlayReserve(), and Game.updater.

Referenced by _OnUpdateInput().

◆ OnBeforeUpdate()

override void AM_Adv.OnBeforeUpdate ( )
inlinevirtual

Reimplemented from ActionMode.

Definition at line 327 of file AM_Adv.cs.

328 {
330 {
331 isMoving = true;
332 }
333 else
334 {
335 isMoving = false;
336 }
337 }
bool isMoving
Definition: AM_Adv.cs:160
virtual bool IsMoving
Definition: CardRenderer.cs:31

References isMoving, CardRenderer.IsMoving, EClass.pc, and Card.renderer.

◆ OnDeactivate()

override void AM_Adv.OnDeactivate ( )
inlinevirtual

Reimplemented from ActionMode.

Definition at line 277 of file AM_Adv.cs.

278 {
279 EndTurbo();
280 }

References EndTurbo().

◆ OnRenderTile()

override void AM_Adv.OnRenderTile ( Point  point,
HitResult  result,
int  dir 
)
inlinevirtual

Reimplemented from ActionMode.

Reimplemented in AM_Region.

Definition at line 282 of file AM_Adv.cs.

283 {
284 if (ShouldHideTile)
285 {
286 return;
287 }
288 EClass.player.currentHotItem.OnRenderTile(point, result, dir);
289 base.OnRenderTile(point, result, dir);
291 {
292 point.Installed.trait.OnRenderTile(point, result, dir);
293 }
295 {
296 return;
297 }
298 foreach (Chara item in point.ListCharas())
299 {
300 if (!item.IsHostile(EClass.pc))
301 {
302 continue;
303 }
304 {
305 foreach (Chara chara in EClass._map.charas)
306 {
307 if (chara.isSynced && chara.IsHostile(EClass.pc) && !chara.IsMultisize)
308 {
309 Vector3 vector = chara.pos.Position();
310 EClass.screen.guide.passGuideFloor.Add(vector.x, vector.y, vector.z - 0.01f, 23f, 0.3f);
311 }
312 }
313 break;
314 }
315 }
316 }
bool ShouldHideTile
Definition: AM_Adv.cs:175
ScreenGuide guide
override bool isSynced
Definition: Chara.cs:676
override bool IsMultisize
Definition: Chara.cs:691
bool IsHostile()
Definition: Chara.cs:5884
static Map _map
Definition: EClass.cs:18
bool highlightArea
Definition: Game.cs:39
virtual void OnRenderTile(Point point, HitResult result, int dir)
Definition: HotItem.cs:116
List< Chara > charas
Definition: Map.cs:81
void Add(Point point, float tile=0f, float color=0f)
Definition: MeshPass.cs:122
Thing Installed
Definition: Point.cs:303
ref Vector3 Position(int height)
Definition: Point.cs:524
MeshPass passGuideFloor
Definition: ScreenGuide.cs:7
virtual void OnRenderTile(Point point, HitResult result, int dir)
Definition: Trait.cs:655
bool IsPCFaction
Definition: Zone.cs:464

References EClass._map, EClass._zone, MeshPass.Add(), Map.charas, Core.config, Game.config, EClass.core, Player.currentHotItem, CoreConfig.game, EClass.game, BaseGameScreen.guide, Game.Config.highlightArea, CoreConfig.GameConfig.highlightEnemy, Point.Installed, Chara.IsHostile(), Chara.IsMultisize, Zone.IsPCFaction, Chara.isSynced, item, HotItem.OnRenderTile(), Trait.OnRenderTile(), ScreenGuide.passGuideFloor, EClass.pc, EClass.player, Card.pos, Point.Position(), EClass.screen, ShouldHideTile, and Card.trait.

◆ OnUpdateCursor()

override void AM_Adv.OnUpdateCursor ( )
inlinevirtual

Reimplemented from ActionMode.

Definition at line 349 of file AM_Adv.cs.

350 {
351 RefreshArrow();
352 CursorInfo info = ((EClass.ui.layers.Count == 0 && !EClass.ui.isPointerOverUI) ? CursorSystem.Instance.arrows[arrowIndex] : null);
353 CursorSystem.leftIcon = null;
354 bool flag = (EClass.pc.ai.IsRunning || turbo != 0f || pressedAction.action != null) && !EClass.pc.HasNoGoal && !(EClass.pc.ai is GoalManualMove);
355 if (flag && !EClass.ui.isPointerOverUI)
356 {
357 CursorSystem.leftIcon = CursorSystem.IconGear;
358 CursorSystem.leftIconAngle = (int)(gearAngle / 45f) * 45;
359 }
361 {
362 updatePlans = true;
363 }
364 if (!ShouldHideTile)
365 {
366 if (planLeft.HasAct)
367 {
368 info = planLeft.CursorIcon;
369 }
370 else if (planRight.HasAct)
371 {
372 info = planRight.CursorIcon;
373 }
374 }
375 gearAngle += Core.gameDelta * 200f;
377 if ((updatePlans && !flag) || EClass.pc.IsDisabled)
378 {
379 UpdatePlans();
380 }
382 {
384 EClass.ui.hud.transRight.SetActive(enable: true);
385 bool flag2 = !ShouldHideTile && !pressedAction.hideRightInfo && !EClass.ui.contextMenu.isActive;
386 EClass.ui.hud.textLeft.SetActive(flag2 && planLeft.ShowAct);
387 EClass.ui.hud.textRight.SetActive(flag2 && planRight.ShowAct);
388 EClass.ui.hud.textMiddle.SetActive(flag2 && textMiddle != null);
389 EClass.ui.hud.textWheel.SetActive(flag2 && textWheel != null);
390 if (EClass.ui.hud.textLeft.gameObject.activeSelf)
391 {
392 EClass.ui.hud.textLeft.rectTransform.anchoredPosition = EClass.ui.hud.leftTextPos * Mathf.Max(1f, EClass.screen.Zoom) / EClass.core.uiScale;
393 }
394 if (EClass.ui.hud.textRight.gameObject.activeSelf)
395 {
396 EClass.ui.hud.textRight.rectTransform.anchoredPosition = EClass.ui.hud.rightTextPos * Mathf.Max(1f, EClass.screen.Zoom) / EClass.core.uiScale;
397 }
398 if (EClass.ui.hud.textMiddle.gameObject.activeSelf)
399 {
400 EClass.ui.hud.textMiddle.rectTransform.anchoredPosition = EClass.ui.hud.wheelTextPos * Mathf.Max(1f, EClass.screen.Zoom) / EClass.core.uiScale;
401 }
402 if (EClass.ui.hud.textWheel.gameObject.activeSelf)
403 {
404 EClass.ui.hud.textWheel.rectTransform.anchoredPosition = (EClass.ui.hud.textMiddle.gameObject.activeSelf ? EClass.ui.hud.wheelTextPos2 : EClass.ui.hud.wheelTextPos) * Mathf.Max(1f, EClass.screen.Zoom) / EClass.core.uiScale;
405 }
406 EClass.ui.hud.imageRight.SetActive(flag2 && planRight.HasAct);
407 }
408 }
string textMiddle
Definition: AM_Adv.cs:154
float gearAngle
Definition: AM_Adv.cs:156
string textWheel
Definition: AM_Adv.cs:152
void UpdateLangWheel()
Definition: AM_Adv.cs:417
int arrowIndex
Definition: AM_Adv.cs:111
virtual void RefreshArrow()
Definition: AM_Adv.cs:1307
bool ShowAct
Definition: ActPlan.cs:246
CursorInfo CursorIcon
Definition: ActPlan.cs:204
bool performed
Definition: ActPlan.cs:153
override bool IsDisabled
Definition: Chara.cs:570
override float uiScale
Definition: Core.cs:95
static int ignoreCount
Definition: CursorSystem.cs:26
List< CursorInfo > arrows
Definition: CursorSystem.cs:32
static CursorInfo IconGear
static void SetCursor(CursorInfo info=null, int _priority=0)
static CursorSystem Instance
Definition: CursorSystem.cs:6
bool hasTargetChanged
Definition: PointTarget.cs:20
bool Equals(int _x, int _z)
Definition: Point.cs:924

References Chara.ai, arrowIndex, CursorSystem.arrows, EClass.core, ActPlan.CursorIcon, cursorMove, Point.Equals(), gearAngle, ActPlan.HasAct, Chara.HasNoGoal, PointTarget.hasTargetChanged, CursorSystem.IconGear, CursorSystem.ignoreCount, CursorSystem.Instance, Chara.IsDisabled, mouseTarget, EClass.pc, ActPlan.performed, planLeft, planRight, ActPlan.pos, PointTarget.pos, RefreshArrow(), EClass.screen, CursorSystem.SetCursor(), ShouldHideTile, ActPlan.ShowAct, textMiddle, textWheel, turbo, EClass.ui, Core.uiScale, UpdateLangWheel(), updatePlans, UpdatePlans(), and BaseGameScreen.Zoom.

◆ PressedActionMove()

bool AM_Adv.PressedActionMove ( Point  pos)
inline

Definition at line 1205 of file AM_Adv.cs.

1206 {
1208 {
1209 return false;
1210 }
1211 if (pos != null)
1212 {
1214 {
1215 if (EClass.pc.pos.Equals(pos) || !pos.IsValid)
1216 {
1217 EClass.player.nextMove = Vector2.zero;
1218 EClass.pc.ai.Cancel();
1219 }
1221 {
1222 if (!EClass.pc.IsEnemyOnPath(pos))
1223 {
1224 EClass.pc.SetAIImmediate(new AI_Goto(pos, 0));
1225 }
1226 }
1227 else
1228 {
1229 EClass.player.nextMove = Vector2.zero;
1230 EClass.pc.ai.Cancel();
1231 }
1232 return false;
1233 }
1235 {
1236 keepWalking = true;
1237 }
1238 }
1239 if (autorun)
1240 {
1241 if (Vector2.Distance(posOrigin, posArrow) > EClass.core.config.game.runDistance)
1242 {
1243 SetTurbo();
1244 }
1245 else if (turbo != 0f && !Input.GetKey(KeyCode.LeftShift) && !EClass.core.config.input.keepRunning && !zoomOut && Vector2.Distance(posOrigin, posArrow) < 1.2f)
1246 {
1247 EndTurbo();
1248 }
1249 }
1250 if (pos != null && !cursorMove)
1251 {
1252 Vector2Int vector2Int = new Vector2Int(pos.x - EClass.pc.pos.x, pos.z - EClass.pc.pos.z);
1253 if (Mathf.Abs(vector2Int.x) > 1 || Mathf.Abs(vector2Int.y) > 1)
1254 {
1255 int num = Mathf.Max(Mathf.Abs(vector2Int.x), Mathf.Abs(vector2Int.y));
1256 vector2Int.x /= num;
1257 vector2Int.y /= num;
1258 }
1259 EClass.player.nextMove = vector2Int;
1260 Point.shared.Set(EClass.pc.pos.x + vector2Int.x, EClass.pc.pos.z + vector2Int.y);
1261 }
1262 else
1263 {
1264 EClass.player.nextMove = vArrow;
1265 Point.shared.Set(EClass.pc.pos.x + (int)vArrow.x, EClass.pc.pos.z + (int)vArrow.y);
1266 }
1268 {
1269 if (EClass.pc.ai is GoalManualMove)
1270 {
1271 EClass.pc.ai.Cancel();
1272 }
1273 return true;
1274 }
1275 if (!Point.shared.IsInBounds)
1276 {
1278 {
1280 return false;
1281 }
1282 if (EClass.pc.ai is GoalManualMove)
1283 {
1284 EClass.pc.ai.Cancel();
1285 }
1286 return true;
1287 }
1288 if (!(EClass.pc.ai is GoalManualMove))
1289 {
1290 if (EClass.pc.HasNoGoal)
1291 {
1292 if (GoalManualMove.CanMove())
1293 {
1294 SetTurbo(EInput.isShiftDown ? (-1) : 0);
1296 }
1297 cursorMove = true;
1298 }
1299 }
1300 else
1301 {
1302 cursorMove = true;
1303 }
1304 return true;
1305 }
Vector2 vArrow
Definition: AM_Adv.cs:123
Vector3 posOrigin
Definition: AM_Adv.cs:119
Vector3 posArrow
Definition: AM_Adv.cs:121
bool IsEnemyOnPath(Point p, bool cancelAI=true)
Definition: Chara.cs:2202
static Point lastlastPoint
static Point lastPoint
void RequestPathImmediate(PathProgress progress)
Definition: PathManager.cs:41
static PathManager Instance
Definition: PathManager.cs:16
bool TooHeavyToMove()
Definition: Player.cs:2331
static Point shared
Definition: Point.cs:20
Point Set(int _x, int _z)
Definition: Point.cs:479
bool IsInBounds
Definition: Point.cs:104

References Chara.ai, autorun, CoreConfig.InputSetting.autowalk, AIAct.Cancel(), Player.CanExitBorder(), GoalManualMove.CanMove(), ButtonState.clicked, Core.config, EClass.core, cursorMove, ButtonState.down, EndTurbo(), Point.Equals(), Player.ExitBorder(), CoreConfig.game, Chara.HasNoGoal, CoreConfig.input, PathManager.Instance, Chara.IsEnemyOnPath(), Point.IsInBounds, EInput.isShiftDown, Point.IsValid, CoreConfig.InputSetting.keepRunning, keepWalking, GoalManualMove.lastlastPoint, GoalManualMove.lastPoint, EInput.leftMouse, EClass.pc, EClass.player, Card.pos, posArrow, posOrigin, PathManager.RequestPathImmediate(), EInput.rightMouse, CoreConfig.GameConfig.runDistance, Point.Set(), Chara.SetAIImmediate(), SetTurbo(), Point.shared, Player.TooHeavyToMove(), turbo, vArrow, Point.x, Point.z, and zoomOut.

Referenced by SetPressedAction().

◆ RefreshArrow()

virtual void AM_Adv.RefreshArrow ( )
inlinevirtual

Reimplemented in AM_Region.

Definition at line 1307 of file AM_Adv.cs.

1308 {
1309 bool flag = zoomOut || EInput.rightMouse.pressedLong;
1310 if (flag && mouseTarget.pos.Equals(EClass.pc.pos))
1311 {
1312 vArrow = Vector2.zero;
1313 EClass.player.nextMove = vArrow;
1314 return;
1315 }
1318 float num;
1319 if (cursorMove || EClass.pc.pos.Distance(base.hit) > 1)
1320 {
1321 num = Util.GetAngle(posArrow.x - posOrigin.x, posArrow.y - posOrigin.y) + 90f + 22.5f;
1322 }
1323 else
1324 {
1325 num = Util.GetAngle(EClass.pc.pos.x - base.hit.x, EClass.pc.pos.z - base.hit.z) - 22.5f;
1326 if (num < 0f)
1327 {
1328 num = 360f + num;
1329 }
1330 }
1331 if ((bool)WidgetUnityChan.Instance)
1332 {
1334 }
1335 if (clickPos != Vector3.zero)
1336 {
1337 if (Vector3.Distance(Input.mousePosition, clickPos) < EClass.core.config.game.angleMargin)
1338 {
1339 return;
1340 }
1341 clickPos = Vector3.zero;
1342 }
1343 vArrow = Vector2.zero;
1344 int _angle = 0;
1345 Action<int, int, int, int> action = delegate(int x, int y, int i, int a)
1346 {
1347 vArrow.x = x;
1348 vArrow.y = y;
1349 arrowIndex = i;
1350 _angle = -a;
1351 };
1352 if (num < 45f || num >= 360f)
1353 {
1354 action(-1, -1, 0, 0);
1355 }
1356 else if (num < 90f)
1357 {
1358 action(-1, 0, 1, 35);
1359 }
1360 else if (num < 135f)
1361 {
1362 action(-1, 1, 2, 90);
1363 }
1364 else if (num < 180f)
1365 {
1366 action(0, 1, 3, 145);
1367 }
1368 else if (num < 225f)
1369 {
1370 action(1, 1, 4, 180);
1371 }
1372 else if (num < 270f)
1373 {
1374 action(1, 0, 5, 215);
1375 }
1376 else if (num < 315f)
1377 {
1378 action(1, -1, 6, 270);
1379 }
1380 else
1381 {
1382 action(0, -1, 7, 325);
1383 }
1384 }
Vector3 clickPos
Definition: AM_Adv.cs:168
static Vector3 position
Definition: CursorSystem.cs:22
static Vector3 posOrigin
Definition: CursorSystem.cs:24
static float GetAngle(Vector3 self, Vector3 target)
Definition: Util.cs:121
void Refresh(float angle)
static WidgetUnityChan Instance

References CoreConfig.GameConfig.angleMargin, arrowIndex, clickPos, Core.config, EClass.core, cursorMove, Point.Distance(), Point.Equals(), CoreConfig.game, WidgetUnityChan.Instance, mouseTarget, EClass.pc, Card.pos, PointTarget.pos, posArrow, CursorSystem.position, Point.PositionCenter(), posOrigin, CursorSystem.posOrigin, ButtonState.pressedLong, WidgetUnityChan.Refresh(), EInput.rightMouse, Util, vArrow, Point.x, Point.z, and zoomOut.

Referenced by Scene.Init(), and OnUpdateCursor().

◆ SetManualMove()

void AM_Adv.SetManualMove ( )
inline

Definition at line 1148 of file AM_Adv.cs.

1149 {
1151 {
1152 SetTurbo(EInput.isShiftDown ? (-1) : 0);
1154 cursorMove = true;
1155 }
1156 }

References cursorMove, EInput.isShiftDown, EClass.pc, EClass.player, Chara.SetAIImmediate(), SetTurbo(), and Player.TooHeavyToMove().

Referenced by AxisMove(), and Scene.Init().

◆ SetPressedAction()

void AM_Adv.SetPressedAction ( ButtonState  button)
inline

Definition at line 1158 of file AM_Adv.cs.

1159 {
1160 if (updatePlans)
1161 {
1162 UpdatePlans();
1163 }
1164 bool flag = button == EInput.leftMouse;
1165 pressedAction.Init(button);
1166 if (isMouseOnMap)
1167 {
1168 if (!flag)
1169 {
1170 if (planRight.HasAct)
1171 {
1173 }
1174 else
1175 {
1176 SE.Play("noAction");
1177 }
1178 return;
1179 }
1180 if (planLeft.HasAct)
1181 {
1183 return;
1184 }
1185 }
1186 if (!flag)
1187 {
1188 return;
1189 }
1190 Point pos = ((!isMouseOnMap) ? null : base.hit.Copy());
1191 if (pos != null && (EClass.pc.pos.Equals(pos) || (EClass.pc.pos.Distance(pos) == 1 && pos.cell.blocked)))
1192 {
1193 return;
1194 }
1196 if (!planLeft.HasAct)
1197 {
1198 clickPos = Input.mousePosition;
1199 pressedAction.SetAction(() => PressedActionMove(pos), _canTurbo: false, _willEndTurn: false, _waitForTurn: false);
1200 pressedAction.repeat = zoomOut;
1201 pressedAction.ignoreCount = true;
1202 }
1203 }
void SetPlan(ActPlan _plan)
Definition: AM_Adv.cs:68
bool PressedActionMove(Point pos)
Definition: AM_Adv.cs:1205
Cell cell
Definition: Point.cs:51

References Algorithms.WeightCell.blocked, Point.cell, clickPos, Point.Distance(), Point.Equals(), ActPlan.HasAct, AM_Adv.PressedAction.Init(), AM_BaseGameMode.isMouseOnMap, EInput.leftMouse, mouseTarget, EClass.pc, planLeft, planRight, Card.pos, pressedAction, PressedActionMove(), AM_Adv.PressedAction.SetAction(), AM_Adv.PressedAction.SetPlan(), ActPlan.Update(), updatePlans, UpdatePlans(), and zoomOut.

Referenced by _OnUpdateInput(), and Scene.Init().

◆ SetTurbo()

void AM_Adv.SetTurbo ( int  mtp = -1)
inline

◆ ShowAllAction()

void AM_Adv.ShowAllAction ( )
inline

Definition at line 1014 of file AM_Adv.cs.

1015 {
1017 if (planAll.HasAct)
1018 {
1020 return;
1021 }
1022 if (EClass._zone.IsRegion)
1023 {
1024 EClass.ui.ToggleLayer<LayerTravel>();
1025 return;
1026 }
1027 if (EClass.debug.godBuild)
1028 {
1029 Thing lastThing = planAll.pos.LastThing;
1030 if (lastThing != null && EClass.pc.pos.Distance(planAll.pos) > 1 && lastThing.W == lastThing.H)
1031 {
1032 lastThing.Rotate();
1033 SE.Rotate();
1034 return;
1035 }
1036 }
1037 SE.BeepSmall();
1038 }
ActPlan planAll
Definition: AM_Adv.cs:147
void ShowContextMenu()
Definition: ActPlan.cs:317
virtual void Rotate(bool reverse=false)
Definition: Card.cs:5479
int H
Definition: Card.cs:2226
bool godBuild
Definition: CoreDebug.cs:303
Thing LastThing
Definition: Point.cs:290

References EClass._zone, EClass.debug, Point.Distance(), CoreDebug.godBuild, Card.H, ActPlan.HasAct, Spatial.IsRegion, Point.LastThing, mouseTarget, EClass.pc, planAll, ActPlan.pos, Card.pos, Card.Rotate(), ActPlan.ShowContextMenu(), EClass.ui, and ActPlan.Update().

Referenced by ActionMode.DoFunc().

◆ ToggleZoom()

void AM_Adv.ToggleZoom ( )
inline

Definition at line 1060 of file AM_Adv.cs.

1061 {
1062 EClass.screen.focusPos = null;
1063 zoomOut2 = !zoomOut2;
1064 SE.Play(zoomOut2 ? "zoomOut" : "zoomIn");
1065 EClass.ui.widgets.OnChangeActionMode();
1066 ClearPlans();
1067 }
void ClearPlans()
Definition: AM_Adv.cs:436
bool zoomOut2
Definition: AM_Adv.cs:105

References ClearPlans(), EClass.ui, and zoomOut2.

Referenced by _OnUpdateInput(), and ActionMode.DoFunc().

◆ TryCancelInteraction()

bool AM_Adv.TryCancelInteraction ( bool  sound = true)
inline

Definition at line 1069 of file AM_Adv.cs.

1070 {
1072 {
1074 {
1075 EClass.pc.ai.Cancel();
1076 if (sound)
1077 {
1078 SE.CancelAction();
1079 }
1080 }
1081 EInput.Consume(consumeAxis: true);
1082 return true;
1083 }
1084 return false;
1085 }

References Chara.ai, AIAct.Cancel(), AIAct.CanManualCancel(), EInput.Consume(), Chara.HasNoGoal, AIAct.IsRunning, and EClass.pc.

Referenced by _OnUpdateInput(), and Chara.Tick().

◆ UpdateLangWheel()

void AM_Adv.UpdateLangWheel ( )
inline

Definition at line 417 of file AM_Adv.cs.

418 {
419 textWheel = null;
420 textMiddle = null;
421 if (planRight.HasAct)
422 {
424 {
425 textWheel = "textWheel_changeHeight".lang();
426 }
427 else if (HotItemHeld.CanRotate())
428 {
429 textMiddle = "textMiddle_rotate".lang(EInput.keys.mouseMiddle.key.ToString() ?? "");
430 }
431 EClass.ui.hud.textWheel.SetText(textWheel.IsEmpty(""));
432 EClass.ui.hud.textMiddle.SetText(textMiddle.IsEmpty(""));
433 }
434 }
KeyMap mouseMiddle
Definition: EInput.cs:135
KeyCode key
Definition: EInput.cs:14
static KeyMapManager keys
Definition: EInput.cs:367

References HotItemHeld.CanChangeHeightByWheel(), HotItemHeld.CanRotate(), Point.Distance(), ActPlan.HasAct, EInput.KeyMap.key, EInput.keys, EInput.KeyMapManager.mouseMiddle, Scene.mouseTarget, EClass.pc, planRight, Card.pos, PointTarget.pos, EClass.scene, textMiddle, textWheel, and EClass.ui.

Referenced by OnUpdateCursor().

◆ UpdatePlans()

void AM_Adv.UpdatePlans ( )
inline

Member Data Documentation

◆ actCount

int AM_Adv.actCount
static

◆ arrowIndex

int AM_Adv.arrowIndex
protected

Definition at line 111 of file AM_Adv.cs.

Referenced by OnUpdateCursor(), RefreshArrow(), and AM_Region.RefreshArrow().

◆ axisTarget

PointTarget AM_Adv.axisTarget
Initial value:
{
mouse = false
}

Definition at line 127 of file AM_Adv.cs.

Referenced by AxisMove().

◆ clickPos

Vector3 AM_Adv.clickPos
protected

Definition at line 168 of file AM_Adv.cs.

Referenced by RefreshArrow(), AM_Region.RefreshArrow(), and SetPressedAction().

◆ cursorMove

bool AM_Adv.cursorMove
protected

◆ gearAngle

float AM_Adv.gearAngle
private

Definition at line 156 of file AM_Adv.cs.

Referenced by OnUpdateCursor().

◆ isMoving

bool AM_Adv.isMoving

Definition at line 160 of file AM_Adv.cs.

Referenced by OnBeforeUpdate().

◆ itemLost

int AM_Adv.itemLost

Definition at line 109 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and Map.TryShatter().

◆ keepWalking

bool AM_Adv.keepWalking
protected

Definition at line 117 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and PressedActionMove().

◆ lastCamPos

Vector3 AM_Adv.lastCamPos
private

Definition at line 162 of file AM_Adv.cs.

◆ movedByKey

bool AM_Adv.movedByKey

Definition at line 107 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and AxisMove().

◆ planAll

ActPlan AM_Adv.planAll
Initial value:
= new ActPlan
{
input = ActInput.AllAction
}

Definition at line 147 of file AM_Adv.cs.

Referenced by HotItemHeld.CanRotate(), and ShowAllAction().

◆ planKeyboard

ActPlan AM_Adv.planKeyboard
Initial value:
= new ActPlan
{
input = ActInput.Key
}

Definition at line 142 of file AM_Adv.cs.

Referenced by AxisMove().

◆ planLeft

ActPlan AM_Adv.planLeft
Initial value:
= new ActPlan
{
input = ActInput.LeftMouse
}

Definition at line 132 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), ClearPlans(), OnUpdateCursor(), SetPressedAction(), and UpdatePlans().

◆ planRight

ActPlan AM_Adv.planRight
Initial value:
= new ActPlan
{
input = ActInput.RightMouse
}

Definition at line 137 of file AM_Adv.cs.

Referenced by ClearPlans(), OnUpdateCursor(), SetPressedAction(), UpdateLangWheel(), and UpdatePlans().

◆ posArrow

Vector3 AM_Adv.posArrow
protected

Definition at line 121 of file AM_Adv.cs.

Referenced by PressedActionMove(), RefreshArrow(), and AM_Region.RefreshArrow().

◆ posOrigin

Vector3 AM_Adv.posOrigin
protected

Definition at line 119 of file AM_Adv.cs.

Referenced by PressedActionMove(), RefreshArrow(), and AM_Region.RefreshArrow().

◆ pressedAction

PressedAction AM_Adv.pressedAction = new PressedAction()

Definition at line 125 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), AxisMove(), OnActivate(), and SetPressedAction().

◆ rightMouseTimer

float AM_Adv.rightMouseTimer

Definition at line 164 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and BaseGameScreen.RefreshPosition().

◆ startedRun

bool AM_Adv.startedRun
private

Definition at line 166 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and AxisMove().

◆ textMiddle

string AM_Adv.textMiddle

Definition at line 154 of file AM_Adv.cs.

Referenced by OnUpdateCursor(), and UpdateLangWheel().

◆ textWheel

string AM_Adv.textWheel

Definition at line 152 of file AM_Adv.cs.

Referenced by OnUpdateCursor(), and UpdateLangWheel().

◆ timerStartRunning

float AM_Adv.timerStartRunning
protected

Definition at line 113 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), and AxisMove().

◆ turbo

float AM_Adv.turbo
static

Definition at line 99 of file AM_Adv.cs.

Referenced by AxisMove(), EndTurbo(), OnUpdateCursor(), PressedActionMove(), and SetTurbo().

◆ updatePlans

bool AM_Adv.updatePlans

Definition at line 158 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), ClearPlans(), OnUpdateCursor(), SetPressedAction(), and UpdatePlans().

◆ vArrow

Vector2 AM_Adv.vArrow
protected

Definition at line 123 of file AM_Adv.cs.

Referenced by PressedActionMove(), RefreshArrow(), and AM_Region.RefreshArrow().

◆ zoomOut

◆ zoomOut2

bool AM_Adv.zoomOut2

Definition at line 105 of file AM_Adv.cs.

Referenced by HotItemContext.Show(), and ToggleZoom().

Property Documentation

◆ AllowWheelZoom

override bool AM_Adv.AllowWheelZoom
get

Definition at line 238 of file AM_Adv.cs.

◆ autorun

bool AM_Adv.autorun
get

Definition at line 172 of file AM_Adv.cs.

Referenced by _OnUpdateInput(), AxisMove(), and PressedActionMove().

◆ FixFocus

override bool AM_Adv.FixFocus
get

Definition at line 198 of file AM_Adv.cs.

199 {
200 get
201 {
202 if (!zoomOut)
203 {
205 {
207 {
209 {
211 {
212 return !(EClass.pc.ai as TaskDesignation).isRepeated;
213 }
214 return true;
215 }
216 return false;
217 }
218 return true;
219 }
220 return true;
221 }
222 return false;
223 }
224 }
static NoGoal _NoGoalRepeat
Definition: Chara.cs:183
bool alwaysFixCamera
Definition: CoreConfig.cs:547

◆ gameSpeed

override float AM_Adv.gameSpeed
get

Definition at line 186 of file AM_Adv.cs.

187 {
188 get
189 {
190 if (!ShouldPauseGame)
191 {
192 return ActionMode.GameSpeeds[EClass.game.gameSpeedIndex] * ((turbo != 0f) ? turbo : 1f);
193 }
194 return 1f;
195 }
196 }
override bool ShouldPauseGame
Definition: AM_Adv.cs:227
static float[] GameSpeeds
Definition: ActionMode.cs:93
int gameSpeedIndex
Definition: Game.cs:223

◆ mouseTarget

PointTarget AM_Adv.mouseTarget
get

◆ ShouldHideTile

bool AM_Adv.ShouldHideTile
get

Definition at line 174 of file AM_Adv.cs.

175 {
176 get
177 {
178 if (EClass.ui.layers.Count <= 0 && (!EClass.pc.renderer.IsMoving || EInput.rightMouse.pressing) && !(EClass.pc.ai.Current is AI_Goto) && !cursorMove && !EClass.ui.isPointerOverUI)
179 {
180 return EInput.axis != Vector2.zero;
181 }
182 return true;
183 }
184 }
AIAct Current
Definition: AIAct.cs:103

Referenced by OnRenderTile(), and OnUpdateCursor().

◆ ShouldPauseGame

override bool AM_Adv.ShouldPauseGame
get

Definition at line 226 of file AM_Adv.cs.

227 {
228 get
229 {
231 {
232 return EClass.pc.HasNoGoal;
233 }
234 return false;
235 }
236 }

◆ TargetZoom

override float AM_Adv.TargetZoom
get

Definition at line 240 of file AM_Adv.cs.

241 {
242 get
243 {
244 if (!zoomOut2)
245 {
246 return 0.01f * (float)EClass.game.config.defaultZoom;
247 }
248 return 0.01f * (float)EClass.game.config.zoomedZoom;
249 }
250 }
int defaultZoom
Definition: Game.cs:63
int zoomedZoom
Definition: Game.cs:66

Referenced by BaseGameScreen.RefreshPosition().


The documentation for this class was generated from the following file: