44using Aarthificial . Typewriter . References ;
55using DevTools . CSV ;
66using Framework ;
7- using Input ;
87using Interactions ;
98using Player ;
109using System . Collections ;
@@ -19,9 +18,7 @@ public partial class GoogleSheetLoader {
1918 private static string _customDocumentId ;
2019 private static string _customSheetName ;
2120
22- [ SerializeField ] [ Inject ] private PlayerChannel _players ;
23- [ SerializeField ] [ Inject ] private InputChannel _input ;
24- [ SerializeField ] [ Inject ] private StoryMode _story ;
21+ [ SerializeField ] [ Inject ] private StoryState _story ;
2522 [ SerializeField ] private DatabaseTable _table ;
2623 [ SerializeField ] private string _documentId ;
2724 [ SerializeField ] private string _sheetName ;
@@ -32,6 +29,11 @@ public partial class GoogleSheetLoader {
3229 private bool _onlyFacts ;
3330 private bool _hideEmpty = true ;
3431 private string _searchText = "" ;
32+ private PlayerManager _players ;
33+
34+ private void Awake ( ) {
35+ _players = GetComponent < PlayerManager > ( ) ;
36+ }
3537
3638 private void OnEnable ( ) {
3739 if ( string . IsNullOrEmpty ( _customDocumentId ) ) {
@@ -58,8 +60,8 @@ private void Open() {
5860 }
5961
6062 _isOpen = true ;
61- _previousMap = _input . CurrentMap ;
62- _input . SetMap ( "None" ) ;
63+ _previousMap = App . Input . CurrentMap ;
64+ App . Input . SetMap ( "None" ) ;
6365 Time . timeScale = 0 ;
6466 }
6567
@@ -69,7 +71,7 @@ private void Close() {
6971 }
7072
7173 _isOpen = false ;
72- _input . SetMap ( _previousMap ) ;
74+ App . Input . SetMap ( _previousMap ) ;
7375 Time . timeScale = 1 ;
7476 }
7577
@@ -78,8 +80,8 @@ private void OnGUI() {
7880 return ;
7981 }
8082
81- var isInConversation = _players . Manager . DialogueState . IsActive
82- && _players . Manager . DialogueState . Context != null ;
83+ var isInConversation = _players . DialogueState . IsActive
84+ && _players . DialogueState . Context != null ;
8385
8486 var size = new Vector2 ( 640 , 160 ) ;
8587 var rect = new Rect (
@@ -162,7 +164,7 @@ private void BlackboardGUI(Rect rect) {
162164
163165 _scrollPosition = GUILayout . BeginScrollView ( _scrollPosition ) ;
164166
165- var context = _players . Manager . DialogueState . Context ;
167+ var context = _players . DialogueState . Context ;
166168 BlackboardEntriesGUI ( context , InteractionContext . GlobalScope ) ;
167169 BlackboardEntriesGUI ( context , InteractionContext . InteractionScope ) ;
168170 BlackboardEntriesGUI ( context , InteractionContext . ContextScope ) ;
0 commit comments