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

Is there any way to code this? #349

Open
Muhframos opened this issue May 18, 2017 · 10 comments
Open

Is there any way to code this? #349

Muhframos opened this issue May 18, 2017 · 10 comments

Comments

@Muhframos
Copy link

Muhframos commented May 18, 2017

image

I have been having some trouble coding stuff like this.
Is it possible to have something like a end of turn effect to target the same thing as the Battlecry targetted?
I changed the wording on it a bit on the code just to make clearer what it does.

Current Code:

{
	"name": "Scary Longlegs",
	"baseManaCost": 3,
	"type": "MINION",
	"baseAttack": 2,
	"baseHp": 2,
	"heroClass": "HUNTER",
	"rarity": "RARE",
	"race": "BEAST",
	"description": "Poisonous. Battlecry: Freeze a minion, at the end of your turn, Freeze it again.",
	"battlecry": {
		"targetSelection": "MINIONS",
		"spell": {
			"class": "AddAttributeSpell",
			"attribute": "FROZEN"
		}
	},
	"triggers": [
		{
		"eventTrigger": {
			"class": "DamageCausedTrigger",
			"targetEntityType": "MINION",
			"hostTargetType": "IGNORE_OTHER_SOURCES"
		},
		"spell": {
			"class": "DestroySpell",
			"target": "EVENT_TARGET"
		}
		},
		{
		"eventTrigger": {
			"class": "TurnEndTrigger",
			"targetPlayer": "SELF"
		},
		"spell": {
			"class": "AddAttributeSpell",
			"target": "EVENT_TARGET",
			"attribute": "FROZEN"
		}
		}
	],
	"attributes": {
	"BATTLECRY": true
	},
	"collectible": true,
	"set": "CLASSIC",
	"fileFormatVersion": 1
}
@webadict
Copy link
Collaborator

You would need to code it as an AddSpellTrigger spell attached to the frozen minion. I think it's possible though.

@Muhframos
Copy link
Author

Muhframos commented May 18, 2017

you mean like Corruption?
I dont think that would work... hmmm
Is there anything that would be able to like, remove the trigger when it dies?

@webadict
Copy link
Collaborator

It could, but you might be better off with the CANNOT_ATTACK attribute instead. Tying it to the entity ID is the hardest part.

@Muhframos
Copy link
Author

Cant i add like, a condition to the trigger, to check if the Scary Longlegs is still on board, to then freeze itself?

@webadict
Copy link
Collaborator

That could work, but I'd be careful with Freeze. Freeze is a specific keyword for not allowing a minion to attack the next time it could. There may be edge cases that would allow you to attack with this minion, so I'd be careful.

If you do Cannot Attack instead, it would definitely not attack. Plus, it's more consistent with the keyword.

@Muhframos
Copy link
Author

hmmm
if i make it to freeze itself at the start and end of every turn, would that still happen? 🤔

@webadict
Copy link
Collaborator

It would probably not, but I never like taking chances.

@DominusMaximus
Copy link

DominusMaximus commented May 19, 2017

how much work would it be to add an attribute that's just used to label an enemy minion so that you can go:

{
"name": "Scary Longlegs",
"baseManaCost": 3,
"type": "MINION",
"baseAttack": 2,
"baseHp": 2,
"heroClass": "HUNTER",
"rarity": "RARE",
"race": "BEAST",
"description": "Poisonous. Battlecry: Choose a minion, it is Frozen while this minion is alive.",
"battlecry":{
"targetSelection": "ALL_MINONS",
"spell": {
"class": "AddAttributeSpell",
"attribute": "ADDED_ATTRIBUTE"
}
},
"aura": {
"class": "AttributeAura",
"target": "ALL_MINIONS",
"attribute": "FROZEN",
"filter": {
"class": "AttributeFilter",
"attribute": "ADDED_ATTRIBUTE"
}
},
"trigger": {
"eventTrigger": {
"class": "DamageCausedTrigger",
"targetEntityType": "MINION",
"hostTargetType": "IGNORE_OTHER_SOURCES"
},
"spell": {
"class": "DestroySpell",
"target": "EVENT_TARGET"
}
},
"attributes": {
"BATTLECRY": true,
"ADDED_ATTRIBUTE":true
}
}

Would it have to be similar to CTHUN_ATTACK_BUFF where the number of Scary Longlegs whose Battlecry has went off is kept track of?

@webadict
Copy link
Collaborator

If you had multiple of those minions, they'd super conflict.

@DominusMaximus
Copy link

Since ADDED_ATTRIBUTE would be updated everytime a Scary Longlegs Battlecry went off, the next one would always get a unique attribute, right?

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