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

added 3 party events #4326

Merged
merged 6 commits into from
Apr 7, 2023
Merged

added 3 party events #4326

merged 6 commits into from
Apr 7, 2023

Conversation

reyaleman
Copy link
Contributor

Pull Request Prelude

Changes Proposed

Added 3 party events

  • Party.onInvite(self, player)
  • Party.onRevokeInvitation(self, player)
  • Party.onPassLeadership(self, player)

Issues addressed:

Rey Alemán added 3 commits February 14, 2023 12:38
Added:
[x] Party.onInvite
[x] Party.onRevokeInvitation
[x] Party.onPassLeadership
@MillhioreBT
Copy link
Contributor

I like onInvite, makes a lot of sense.
However the other two methods, mmmm are not very consistent.
I don't see valid reasons to use them.

Deny a player to revoke an invitation? because?
Deny one player passing the leadership to another? because?

Suppose I return false in the Party.onPassLeadership event then I can't make anyone else a leader anymore, but if the leader dies or the player gets kicked off the server what happens? rule is violated, leadership now belongs to the next member...

I think my mind is very closed right now, so I hope you can show some good examples to learn a bit about how to use these two methods.

@Tofame
Copy link
Contributor

Tofame commented Mar 23, 2023

@MillhioreBT deny...? Are those only for denying, or are those to run a script when something is happening e.g. when inviting.
If the latter then those could be useful for writing some otclient modules.

@EPuncker EPuncker merged commit 8646e88 into otland:master Apr 7, 2023
@reyaleman reyaleman deleted the party-events branch May 4, 2023 16:31
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

Successfully merging this pull request may close these issues.

None yet

4 participants