Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify spellcasting. #60

Closed
viking-sudo-rm opened this issue Sep 10, 2018 · 0 comments
Closed

Simplify spellcasting. #60

viking-sudo-rm opened this issue Sep 10, 2018 · 0 comments

Comments

@viking-sudo-rm
Copy link
Member

I've decided to simplify spellcasting a bit. Now, each item implements an onCast method, which takes a CastEvent. This allows information about cast position, etc. to be passed in from the context.

Note that sy (it/mouse) will always refer to the dynamic (i.e. runtime) mouse position, whereas the second person object now refers to either the object that the spell was cast on or a blank entity at the initial cast position.

One immediate consequence of this is that Open will be refactored to be intransitive. It will always use the second person object as the position for opening. This makes its behavior more intuitive. Just write wpi on a sling or target a papyrus with wpi on a door and it should work as intended.

Since using Open is the first step in the tutorial, it lets us start with a non-compositional spell, and then introduce a compositional spell in stage 2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant