[Adventurer] Mushroom Noise


#1

The new desert level with pets: Mushroom Noise.

This level continues the series about pet.findNearestByType method.

Pets can help you to recognise enemies too, not only items.


#2

good one but short =)


#3

Hello,

I run into some trouble with the level using Python. The pet won’t listen, he just follows me. And it comes up with an error regarding the Skeleton.

I am wondering if mine glitched due to already having a pet. The other similar levels allow me to start without a pet selected and give me a default pet. And I have to use the default pet for them to work.

This level however, wouldn’t allow me to start without my pet equipped. Thank you for your time.


#4

its mistake in the function for pet

pet.fetch( item )

instead

pet.fetch( potion )

#5

pet.fetch(item) – what is item in your code?


#6

Oh thank you both very much, I had item instead of the potion variable that was set up, as you said. It works now. I wonder why it pointed out that the skeleton was wrong rather than the item.

Edited: To thank both htrnblr and Bryukh.


#7

Any mistake in
Event handler function will be shown in main loop somewhere
your only help is the error message itself

Also you can run event handler function by itself without event
instead

 pet.on( "spawn", onSpawn )

use

onSpawn()

in main loop
for debug
in this case mistake will be handled right


#8

Thank you again for explaining it. I’m sure the tip will be useful on other levels as well.