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

Deathrattle #5

Open
clayjacobs opened this issue Jul 22, 2014 · 4 comments
Open

Deathrattle #5

clayjacobs opened this issue Jul 22, 2014 · 4 comments

Comments

@clayjacobs
Copy link
Contributor

There is a way already to do battle cries, but I've been looking and I can't seem to find any code to handle death rattles. Is this correct or am I just missing it?

@oyachai
Copy link
Owner

oyachai commented Jul 22, 2014

There is a trigger for it... kinda. Every minion death should trigger a call to Minion.destroyed(), so the plan is to have death rattle minions override destroyed() to do its effects. It is untested though, and the destroyed() trigger order is certainly wrong. My idea to fix the ordering issue is to wrap the p0_minions_ and p1_minions_ list within a custom list class that returns an iterator in the right order (FIFO). Definitely open to suggestions though.

@oyachai
Copy link
Owner

oyachai commented Jul 23, 2014

Added an example Deathrattle implementation, Loot Hoarder.

@clayjacobs
Copy link
Contributor Author

Awesome, I'll work on some minions with death rattle. Thanks for the quick update.

@MrHen
Copy link
Contributor

MrHen commented Apr 8, 2015

This can probably be closed now since we've continued to add Deathrattle support.

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

3 participants