When I summon an Enderdragon using command blocks, how do I do so in such a way that when killed, it won't drop an end portal? As a bonus, can I make it drop the egg without also dropping the portal?
Thanks in advance for any help.
Rollback Post to RevisionRollBack
"I'm an engineer. That means I solve problems. Not problems like,
'What is beauty?', because that would fall within the purview of your
conundrums of philosophy. I solve practical problems."
If you know the rough area where the dragon will die, you can use /setblock to convert all of the blocks in that area to air. If you'd like, you can then use /setblock again to make one of the air blocks into a dragon egg.
Rollback Post to RevisionRollBack
If you found my post helpful, please click that green up arrow over there!
To my knowledge, neither of those things are possible... Why don't you want the portal?
Idea I had for "Random" dragon bosses in the over world. Ah well.
Rollback Post to RevisionRollBack
"I'm an engineer. That means I solve problems. Not problems like,
'What is beauty?', because that would fall within the purview of your
conundrums of philosophy. I solve practical problems."
Try using a clock testing for an end ender dragon with a heath of 1 so when its heath is low it will kill it with a command. If you use a command to kill it it might not spawn a portal. If it still does have a clock that instead teleports all dragons with a health of 1 to a lava pit to kill it, then the portal will be somewhere away from players. Hope this helps!
I don't know about this but I think you'll have to use command blocks.
You could use a command block to constantly set a scoreboard value of any dragon with a health of , to 1.
Then another to constantly teleport a WitherSkull to an Enderdragon with a scoreboard value of 1.
When the dragon dies, the WitherSkull will be left in the place where the dragon was,
then you can use an execute command to fill an area under the WitherSkull with air, effectively clearing the portal (portals are always spawned a certain number of blocks or less under the dragon),
then summon a Dragon Egg entity at the WitherSkull.
This is what my brain schemed up, it may too complicated for what you want but I'll test it out then post back with the commands.
Try using a clock testing for an end ender dragon with a heath of 1 so when its heath is low it will kill it with a command. If you use a command to kill it it might not spawn a portal. If it still does have a clock that instead teleports all dragons with a health of 1 to a lava pit to kill it, then the portal will be somewhere away from players. Hope this helps!
This would work you would just have to raise the minimum health for it to be kill because there is a low chance of getting exactly 1 probs raise it to 5 or something. Also instead of the lava pit you could tp DEEP down into the void which would kill it and as most know blocks can't be placed/summoned in the void
Rollback Post to RevisionRollBack
"If at first you don't succeed, then you fail."
- Glados
Yeah I got command blocks is there a way to detect when the dragon dies then clear the portal? I don't want the chat to be spammed "0blocks cleard"
You can test when something has 0 health by making the scoreboard objective for health
/scoreboard objectives add Name health Name
You can then have a fill clock connected to /testfor @e[type=Enderdragon,score_Name=0] which will detect any enderdragons with 0 health (dead)
I'm not so sure about how to perfectly clear away the endportal, but you can easily stop the chat spam by doing /gamerule commandBlockOutput false
Try using a clock testing for an end ender dragon with a heath of 1 so when its heath is low it will kill it with a command. If you use a command to kill it it might not spawn a portal. If it still does have a clock that instead teleports all dragons with a health of 1 to a lava pit to kill it, then the portal will be somewhere away from players. Hope this helps!
This seems like it would work. Also, the new 1.8 fill command (as already mentioned) should work as well.
Never have thought of this. This would be a cool addition to a map. Good luck btw.
Thanks in advance for any help.
"I'm an engineer. That means I solve problems. Not problems like,
'What is beauty?', because that would fall within the purview of your
conundrums of philosophy. I solve practical problems."
v
Idea I had for "Random" dragon bosses in the over world. Ah well.
"I'm an engineer. That means I solve problems. Not problems like,
'What is beauty?', because that would fall within the purview of your
conundrums of philosophy. I solve practical problems."
You could use a command block to constantly set a scoreboard value of any dragon with a health of , to 1.
Then another to constantly teleport a WitherSkull to an Enderdragon with a scoreboard value of 1.
When the dragon dies, the WitherSkull will be left in the place where the dragon was,
then you can use an execute command to fill an area under the WitherSkull with air, effectively clearing the portal (portals are always spawned a certain number of blocks or less under the dragon),
then summon a Dragon Egg entity at the WitherSkull.
This is what my brain schemed up, it may too complicated for what you want but I'll test it out then post back with the commands.
This would work you would just have to raise the minimum health for it to be kill because there is a low chance of getting exactly 1 probs raise it to 5 or something. Also instead of the lava pit you could tp DEEP down into the void which would kill it and as most know blocks can't be placed/summoned in the void
- Glados
You can test when something has 0 health by making the scoreboard objective for health
/scoreboard objectives add Name health Name
You can then have a fill clock connected to /testfor @e[type=Enderdragon,score_Name=0] which will detect any enderdragons with 0 health (dead)
I'm not so sure about how to perfectly clear away the endportal, but you can easily stop the chat spam by doing /gamerule commandBlockOutput false
This seems like it would work. Also, the new 1.8 fill command (as already mentioned) should work as well.
Never have thought of this. This would be a cool addition to a map. Good luck btw.
Life is a game, if you can't win don't play.
-Seto Kaiba
Put this command on a clock:
execute @e[type=EnderDragon] ~ ~ ~ /fill ~ ~ ~ ~-90 ~-50 ~-30 air