Bows immune

Post Reply
User avatar
Steamed_Punk
Member
Posts: 156
Joined: Sat Aug 10, 2019 13:31
GitHub: steamed-punk

Bows immune

by Steamed_Punk » Post

I am trying to make a buffalo mob that can only be hunted and killed by a bow by doing this.

Code: Select all

immune_to = {
		{"all", 0},
		{"bows:bow", 10},
	},
It didn't work so i tried this:

Code: Select all

	immune_to = {
      {"all"},
      {"bows:bow", 100},
   },
That didn't work either

So i went back to the example in the mobs_redo.api ' default sword' and it worked.
I don't think that 'ALL' works with the list. It seems to outright override everything.

Is that correct and all i need to do and add to my mod to make the buffalo hunt-able by bow from the bows mod?
I also placed bows it in the depends.lua

Thanks in advance for any pointers

regards
The sky is not the limit - It's my playground

User avatar
Skamiz Kazzarch
Member
Posts: 618
Joined: Fri Mar 09, 2018 20:34
GitHub: Skamiz
In-game: Skamiz
Location: la lojbaugag.

Re: Bows immune

by Skamiz Kazzarch » Post

As a disclaimer I have zero experience with mobs_redo or even entities in minetest in general, but...
What are the odds that: {"bows:bow", 10} means that the damage is dealt by the bow? I mean, have you literaly walked up to the buffalo and hit it with the bow item?
I am guessing that the arrow itself registers the hit differently than if you hit the mob with something you hold in your hand.
Hope that helps.

User avatar
TenPlus1
Member
Posts: 3721
Joined: Mon Jul 29, 2013 13:38
In-game: TenPlus1
Contact:

Re: Bows immune

by TenPlus1 » Post

Try:

Code: Select all

immune_to = {
    {"bows:bow_wood", 100},
    {"all"},
},

Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests