[Mod] Goblins [WIP][mobs_goblins]

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Thu Sep 03, 2015 14:49

Ferk wrote:I think that as a WIP mod that's fine, but maybe the goblins should be less common and a bit more concentrated in particular areas. So that it's more of a discovery to manage to find a den of goblins. You still could get some solitary goblin explorer that starts messing up your cave, but it shouldn't be as frequent as in the WIP version of the mod.


I've boosted the chance of encountering goblins considerably since the first iteration as they were a bit too rare for my personal taste. I'll probably dial this down once they are spawning in more interesting ways, as I get closer to non-wip status, and include an easier way to configure this.

Though I agree they should dig the floor much less frequently than the walls, they always end up building pits and killing themselves on them. It would be cool if they made actual passages. Maybe make it so if the dig direction is not down, instead of just removing 1 block, remove 2 so that they can go through the hole, and then make them walk into it and have a bigger chance to continue digging straight in the same direction. Probably this alone would make it more likely for them to create random passages in crazy patterns, like a maze.

They would still destroy your cave structure anyway but that's not necessarily a bad thing they are goblins after all, they should be annoying :P


I think I can make this work without fuss. Currently all goblins search in all directions to replace nodes. Adding another replacement function for more specialized behavior is planned. There will be pit digging goblins returning at some point though, for making nasty traps, but getting goblins to avoid these traps themselves will be a bit more work.

Then when you find those random patterns when you are exploring you will immediately realise: this is goblins work! they must be close..


That is certainly the idea. I think minetest needs the option for creatures that actually interact with the world (including things made by the player) and change it. Entropy acts upon everything we do in the real world and makes for challenge, why should that not be the case here?
 

User avatar
duane
Member
 
Posts: 1417
Joined: Wed Aug 19, 2015 19:11
Location: Oklahoma City
GitHub: duane-r

Re: [WIP] Goblins [mobs_goblins]

by duane » Fri Sep 04, 2015 06:54

Ferk wrote:I think that as a WIP mod that's fine, but maybe the goblins should be less common and a bit more concentrated in particular areas.


I definitely don't want them much rarer. I'm growing more and more fond of them, and once you start mining out the ore, they vamoose pretty quickly as it is. I've been exploring a big cave with three waterfalls in it that twisted and turned quite a bit when I first saw it. After a couple of (RL) days visiting it occasionally, they managed to dig some grueling 3D mazes that went up over and through all the ore. I wasn't worried about falling so much as digging in the wrong place and drowning myself. (I thought I was good at placing torches, but a couple of times I got confused and was down to no air before I managed to breathe.)

I'd love to start a contest for screenshots of the most complicated maze, but a 2D picture would never do them justice.

As much as it would irritate me, I think they ought to have the option to steal the ore (or maybe some types -- they might only care about steel for weapons, or just precious metals). It doesn't make much sense otherwise. On the other hand, that would prompt me to kill them off, and I wouldn't get to see the complicated mazes.

They've also been surprisingly hesitant to steal my torches. I left them everywhere, and only a few vanished. They mostly dug and cobbled.

Another thing that would be really cool would be if we could make their eyes glow in the dark... really obviously, so you see lots of little glowing eyes in the distance when you enter a cavern. Maybe a darker texture with exaggeratedly bright eyes (and possibly emitting light 1) which changes to the normal one when the player gets closer?
Believe in people and you don't need to believe anything else.
 

User avatar
Nathan.S
Member
 
Posts: 876
Joined: Wed Sep 24, 2014 17:47
Location: Bigsby Texas
GitHub: NathanSalapat
IRC: NathanS21
In-game: NathanS21

Re: [WIP] Goblins [mobs_goblins]

by Nathan.S » Fri Sep 04, 2015 12:26

Glowing eyes would be cool, not sure if that could readily be implemented though, but I'm in favour of it.
I record Minetest videos, Mod reviews, Modding tutorials, and Lets plays.
Check out my website, and brand new Minetest Modding Course
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Fri Sep 04, 2015 14:35

duane wrote:As much as it would irritate me, I think they ought to have the option to steal the ore (or maybe some types -- they might only care about steel for weapons, or just precious metals). It doesn't make much sense otherwise. On the other hand, that would prompt me to kill them off, and I wouldn't get to see the complicated mazes.

They've also been surprisingly hesitant to steal my torches. I left them everywhere, and only a few vanished. They mostly dug and cobbled.

Another thing that would be really cool would be if we could make their eyes glow in the dark... really obviously, so you see lots of little glowing eyes in the distance when you enter a cavern. Maybe a darker texture with exaggeratedly bright eyes (and possibly emitting light 1) which changes to the normal one when the player gets closer?


I thought about them stealing ore, but I think that could be frustrating for the player, as their ai can "sense" ore even behind layers of rock currently. For this to work, they would have to put this in some kind of inventory and drop upon kill. Because the eventually expire, I'm not sure I want them to leave a pile of ore behind and have players just waiting for them to do all the mining and die. Perhaps if they were all aggressive and made it a challenge to have them running about mining?
 

User avatar
Don
Member
 
Posts: 1643
Joined: Sat May 17, 2014 18:40
GitHub: DonBatman
IRC: Batman
In-game: Batman

Re: [WIP] Goblins [mobs_goblins]

by Don » Fri Sep 04, 2015 14:40

With goblins digging, if I play every day for an hour after a year of playing how much of the ground would be gone?
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!

A list of my mods can be found here
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Fri Sep 04, 2015 23:26

Update Goblins with (hopefully) improved search and replace:
from the new api.lua :
Code: Select all
      search_rate = def.search_rate, --how often to we search for nodes?
      -- how often do we lookfor nodes above or below? (relative to nodes around us, will be same if undefined)
      search_rate_above = def.search_rate_above or 1,
      search_rate_below = def.search_rate_below or 1,
      -- how far away can we look for nodes?
      search_offset = def.search_offset or 0,
      search_offset_above = def.search_offset_above or 0,
      search_offset_below = def.search_offset_below or 0,
      replace_rate = def.replace_rate, -- how likely is a node we found replaced?
      -- what nodes will be replaced?
      replace_what = def.replace_what,
      replace_with = def.replace_with,

With this functionality the diggers seem to dig better tunnels. I also adjusted the collision box for goblins so that they can fit in a 1 node high tunnel... this should make following diggers a bit more challenging. Cobblers are also far more industrious this time around.
 

User avatar
duane
Member
 
Posts: 1417
Joined: Wed Aug 19, 2015 19:11
Location: Oklahoma City
GitHub: duane-r

Re: [WIP] Goblins [mobs_goblins]

by duane » Sat Sep 05, 2015 04:36

FreeLikeGNU wrote:I thought about them stealing ore, but I think that could be frustrating for the player, as their ai can "sense" ore even behind layers of rock currently.


I'd definitely make it optional, disabled by default, but as things are, they expose all the ore in an area, so it's really no different than just going out and picking it up. I was mainly thinking that it makes mining too easy, but of course more aggression would counter that. You might also consider having one type that randomly moves ore around without pocketing it -- maybe they like to line their lairs/tunnels with it.

I hope that at some point they'll build tunnels that connect a lot of caves together, making mods like intersection less necessary. It seems silly, considering how easy it is to dig in this game, but it's much more fun for me to find a tunnel or cave than it is to make one.

With this functionality the diggers seem to dig better tunnels. I also adjusted the collision box for goblins so that they can fit in a 1 node high tunnel... this should make following diggers a bit more challenging. Cobblers are also far more industrious this time around.


Oooo. Short collision box. That's just not fair. I have to find time this weekend to check it out.
Believe in people and you don't need to believe anything else.
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Sat Sep 05, 2015 13:45

I've re-written Goblins to use Mobs Redo as a base without changing the Api, and using the do_custom function from within mob definitions to dig/mine/take torches etc instead...

Update (7 Sep '15): the do_custom routine uses the original search & replace code from the main mod only included in goblin definition instead of changing api...
Attachments
goblins_redo.zip
(191.9 KiB) Downloaded 934 times
Last edited by TenPlus1 on Mon Sep 07, 2015 10:38, edited 3 times in total.
 

User avatar
ArguablySane
Member
 
Posts: 116
Joined: Sun Oct 12, 2014 21:29

Re: [WIP] Goblins [mobs_goblins]

by ArguablySane » Sat Sep 05, 2015 14:18

duane wrote:I hope that at some point they'll build tunnels that connect a lot of caves together, making mods like intersection less necessary. It seems silly, considering how easy it is to dig in this game, but it's much more fun for me to find a tunnel or cave than it is to make one.

It would be cool to make their tunneling/building behaviour less random. My suggestion would be as follows:

First, they don't spawn randomly. Goblins spawn inside lair/nest/cave things which are generated randomly underground. These can start off unconnected to anything else, but that will soon change.

To add more coherence to their digging, each tribe of goblins should have a plan of the tunnels they want to dig out. This could be generated in a very similar way to any normal cave/building generator, but rather than carving it into the map it should be saved somewhere for later use. Now, the digger goblins simply find bits of rock which are marked as open space on the plan and remove them, while the builder goblins build bridges wherever a tunnel intersects a natural cave.
If you wanted to, you could use various tricks to make this tunnel network "plan" extend across the entire map so the goblins never run out of things to do.
The above post and any ideas expressed therein are released to the public domain under a Creative Commons CC0 license.
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Sat Sep 05, 2015 15:07

TenPlus1 wrote:I've re-written Goblins to use Mobs Redo as a base without changing the Api, and using the do_custom function from within mob definitions to dig/mine/take torches etc instead...


Wow, thanks for merging the goblins to work with upstream mobs_redo!

EDIT: @TenPlus1: currently they only spawn, but the goblins don't act on nodes and debugging is broken... I'm testing with latest mobs redo.
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Sat Sep 05, 2015 16:46

Each goblin now has a do_custom function within their mob register routines that control the search and replacement feature you added but using a local function instead of changing the global api itself... I tested the cobble goblin and it removed stone and torches to replace with moddycobble so works ok, and the do_custom function is called every 1 second like the previous replace_what/replace_with feature in the api... If some of the goblins dont act as planned check the values entered to see if I changed any by mistake...
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Sat Sep 05, 2015 17:26

TenPlus1 wrote:Each goblin now has a do_custom function within their mob register routines that control the search and replacement feature you added but using a local function instead of changing the global api itself... I tested the cobble goblin and it removed stone and torches to replace with moddycobble so works ok, and the do_custom function is called every 1 second like the previous replace_what/replace_with feature in the api... If some of the goblins dont act as planned check the values entered to see if I changed any by mistake...


hmm, I tested the digger and cobble goblins, but again they do not act on nodes.... I have mobs and goblins mods active in my test map with the mods in the paths:

minetest/mods/mobs (latest git)
minetest/mods/goblins (from your zip)

Is there something I'm missing here?
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Sat Sep 05, 2015 18:13

Hrm, let me re-check the function and it's settings...
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Sat Sep 05, 2015 18:18

mobs_goblins updated: digger has his own skin and made some adjustments to s&r (search and replace) parameters so that replacement is closer to the goblin entity.
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Sat Sep 05, 2015 19:51

do_custom code simplified and working for each goblin type, also added spawn eggs and new digger texture: viewtopic.php?f=9&t=13004&p=189917#p189917
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Sun Sep 06, 2015 02:01

TenPlus1 wrote:do_custom code simplified and working for each goblin type, also added spawn eggs and new digger texture: viewtopic.php?f=9&t=13004&p=189917#p189917

TenPlus1,
goblins are working now, however the simplifications do not allow for varying the frequency of replacing nodes above or below relative to whats around the mob. This is kind of important for the digger so it's not digging straight down as much is around.
The other goblins need to replace nodes that are higher so that they are effective at stealing torches, cobbling, and other nasty things :D

I really like the cleaner code though and I will probably use it in the standalone mobs_goblins as well. Again, many thanks for your port! I have it in a git repo now and will add that to my OP!

I've also added you to the repo: https://github.com/FreeLikeGNU/goblins
FLG
 

User avatar
duane
Member
 
Posts: 1417
Joined: Wed Aug 19, 2015 19:11
Location: Oklahoma City
GitHub: duane-r

Re: [WIP] Goblins [mobs_goblins]

by duane » Sun Sep 06, 2015 02:42

ArguablySane wrote:To add more coherence to their digging, each tribe of goblins should have a plan of the tunnels they want to dig out. ... Now, the digger goblins simply find bits of rock which are marked as open space on the plan and remove them, while the builder goblins build bridges wherever a tunnel intersects a natural cave.


I don't like the idea of limiting their spawn locations, but the rest sounds awesome, if ambitious.

I've re-written Goblins to use Mobs Redo as a base without changing the Api, and using the do_custom function from within mob definitions to dig/mine/take torches etc instead...


Good to see everybody collaborating. Keep it up, guys.

I keep trying to make glowing eyes work, but I'm having zero luck. I can't find any way to change an object's lighting without lighting up everything else, and the eyes don't show up in the dark, no matter what color they are. Meh.
Believe in people and you don't need to believe anything else.
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU
 

User avatar
ArguablySane
Member
 
Posts: 116
Joined: Sun Oct 12, 2014 21:29

Re: [WIP] Goblins [mobs_goblins]

by ArguablySane » Sun Sep 06, 2015 17:41

duane wrote:I don't like the idea of limiting their spawn locations, but the rest sounds awesome, if ambitious.

On further consideration, you wouldn't need to limit their spawn locations. Just have a single tunnel network planning algorithm shared between them all.
The only part I haven't figured out is how to give them an efficient way to find nearby blocks which need to be dug out. It would be very inefficient to have them constantly checking every block around them and measuring its distance from several hundred nearby points and lines. Maybe they first find a point they can path to where one of the planned tunnels intersects open air, then start doing a naive search on nearby blocks and adding them to a digging queue.
It's definitely ambitious, but it's also definitely possible.

duane wrote:I keep trying to make glowing eyes work, but I'm having zero luck. I can't find any way to change an object's lighting without lighting up everything else, and the eyes don't show up in the dark, no matter what color they are. Meh.

I've tried to do this before and didn't have any luck. I don't think it's possible in the current engine.
The above post and any ideas expressed therein are released to the public domain under a Creative Commons CC0 license.
 

User avatar
FreeLikeGNU
Member
 
Posts: 125
Joined: Tue Oct 28, 2014 02:50
GitHub: FreeLikeGNU
IRC: freelikegnu
In-game: FreeLikeGNU

Re: [WIP] Goblins [mobs_goblins]

by FreeLikeGNU » Sun Sep 06, 2015 18:19

ArguablySane wrote:
duane wrote:I keep trying to make glowing eyes work, but I'm having zero luck. I can't find any way to change an object's lighting without lighting up everything else, and the eyes don't show up in the dark, no matter what color they are. Meh.

I've tried to do this before and didn't have any luck. I don't think it's possible in the current engine.


Yeah it would be nice if we could use a texturemap for luminescence like we can for bumpmaps. This would open a whole lot of possibilities, unless this exists already?
 

User avatar
duane
Member
 
Posts: 1417
Joined: Wed Aug 19, 2015 19:11
Location: Oklahoma City
GitHub: duane-r

Re: [WIP] Goblins [mobs_goblins]

by duane » Mon Sep 07, 2015 09:42

FreeLikeGNU wrote:Yeah it would be nice if we could use a texturemap for luminescence like we can for bumpmaps. This would open a whole lot of possibilities, unless this exists already?


I tried changing the lighting directly with voxelmanip, but I think the normal calculation just writes over it again. It didn't seem to make any difference.
Believe in people and you don't need to believe anything else.
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Mon Sep 07, 2015 10:40

Updated Goblins redo to use original search & replace code within do_custom, should work same as original now :) Mobs Redo mod updated also with some new additions to help...

viewtopic.php?f=9&t=13004&p=189917#p189917
 

User avatar
Ferk
Member
 
Posts: 337
Joined: Tue Aug 18, 2015 17:18
GitHub: Ferk

Re: [WIP] Goblins [mobs_goblins]

by Ferk » Mon Sep 07, 2015 10:52

TenPlus1 wrote:Updated Goblins redo to use original search & replace code within do_custom, should work same as original now :) Mobs Redo mod updated also with some new additions to help...


Nice! mobs_redo is looking more and more as THE api for mobs.
Hopefully we will start having a clear winner in this mess of incompatible mob mods.

I wonder: if we actually get a client-side lua API in Minetest 0.5 would you say mobs_redo would be able to benefit from it in any way? Do you think an entire new mod would have to be made? or maybe client-side scripting alone wouldn't really help and something else would be needed?

[/sorry for off-topic]
{ ☠ Dungeontest ☠ , ᗧ••myarcade•• }
 

User avatar
benrob0329
Member
 
Posts: 1274
Joined: Thu Aug 06, 2015 22:39
Location: Michigan
GitHub: Benrob0329
IRC: benrob0329
In-game: benrob03

Re: [WIP] Goblins [mobs_goblins]

by benrob0329 » Mon Sep 07, 2015 15:44

The devs are working on a C++ mobs API, so the mobs here would have to be ported.
 

User avatar
TenPlus1
Member
 
Posts: 2562
Joined: Mon Jul 29, 2013 13:38
GitHub: tenplus1

Re: [WIP] Goblins [mobs_goblins]

by TenPlus1 » Mon Sep 07, 2015 15:51

Having a c++ implementation for mob registration with custom functions which can be run inside lua would be an amazing feat for the default game... That would mean the initial c++ api would do all of the work and be flexible enough to run specific tasks for any kind of mob we can think of...
 

PreviousNext

Return to WIP Mods



Who is online

Users browsing this forum: No registered users and 3 guests