generated from Alorel/basic-library-template-repo
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Stop running from combat on action execution
Closes #152
- Loading branch information
Showing
4 changed files
with
38 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import type {Observable} from 'rxjs'; | ||
import {Subject} from 'rxjs'; | ||
import {take} from 'rxjs/operators'; | ||
import LazyValue from './lazy-value.mjs'; | ||
|
||
export const tickEnd$ = new LazyValue<Observable<void>>(() => { | ||
const out = new Subject<void>(); | ||
ctx.patch(Game, 'tick').after(() => { | ||
out.next(); | ||
}); | ||
|
||
return out; | ||
}); | ||
|
||
export const nextTickEnd$ = new LazyValue<Observable<void>>(() => tickEnd$.value.pipe(take(1))); |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters