MirceaKitsune wrote:This means that during the day, people roam freely while monsters will retreat in caves or under the shades of trees... whereas during the night, monsters will walk everywhere while people will gather around areas lit by torches.
MirceaKitsune wrote: This fully allows the behavior villagers have in Minecraft, where each villager goes outside during the day but in a house during the night... with the only exception that mobs can't open and close doors on their own yet.
Sokomine wrote:Sounds fine. I'd love it if sheep where to roam around during the day, but would try to seek other sheep during the night. Other animals might also seek a tree and gather below that. Or - more practical perhaps - animals gathering at night at a hen house or at their feeding place. Though farm animals would be diffrent insofar as they'd be far more stupid than other mobs and would not require an intelligent movement algorithm. For those farm animals, fast execution and extremly low load for a server are the most important factors. Plus beeing protected from griefers (=players who want to kill/pick them up). Guess I'll eventually have to write such a mod.
Sokomine wrote:I don't want to duplicate MC behaviour as such. The ideal behaviour for villagers might be to walk around randomly during the day, gather in the church or pub in the evening, and then go to their respective homes. I've got the villages as such mostly ready, the data structure of the villages is stored (it is known where each house is and what type it is; the road system is known), and the trading functionality is implemented in mobf_trader. These traders so far only know how to stand around all day. I'm not sure if there's a good way to handle a larger village where the mob might get too far away from his home and beeing unloaded. Or in how far simulation of villager behaviour is beneficial to gameplay as such. Pathfinding can even be pretty easy in that case as the area is flat and the village structure known.
MirceaKitsune wrote:However, friendly mobs tend to follow each other all the time... so if one sheep walks to safety as night falls, nearby sheep should follow it.
MirceaKitsune wrote:First of all, each type of building (church, pub, etc) should have an unique node as the floor, since the node name / group to walk on is currently used in detection.
Sokomine wrote:Unique floors would be a bit difficult. It's easier in this case to supply the mob with coordinates directly. It's probably a diffrent way of application of movement/pathfinding. I hope to get far enough soon so that mobs can be placed into the villages and experiments regarding their behaviour beeing conducted. The requirements may be diffrent from free-moving mobs such as these here.
twoelk wrote:That is if doors could be convinced to accept certain mobs to interact with them.
twoelk wrote:So if the mobs examine the nodes under or near their feet they will not step into plain air anymore and fall of cliffs? They also notice when in water and can be told to search the next coast?
twoelk wrote:Guess I should play with this mod a little more so that I might know all it's possabilities, ... , ..., hmm, playing with electronic sheep, ... , that reminds me of something, ... , do they dream?
MirceaKitsune wrote:Today I implemented another plan I've had for a while: Mobs now have names, which are attributed randomly per individual! They are defined as nested tables, meaning that the first name and last name will each be random. Only the human mobs use this so far.
TeTpaAka wrote:First of all, this is a very interessting mod. It adds a new aspect to the gameplay.
But in the current version you cannot possess a sheep or a rat. The sheep drops wool and the rat gets picked up. I think this has to do with the change of the default behavior to possess. All other creatures show a formspec in the code, except for these two.
Also I wonder if it would be possible to change the visual abilities of the creatures, so mobs that live in the dark would see better in caves, for example? Just for curiosity.
TeTpaAka
Don wrote:I call it Exeterbunny
local colors_fur = {
"#ff0000", -- red
"#ffcc00", -- orange
"#ffff00", -- yellow
"#ffffff", -- white
"#cccccc", -- gray
"#000000", -- black
}
local colors_eyes = {
"#ff0000", -- red
"#ffff00", -- yellow
"#00ff00", -- green
"#00ffff", -- cyan
"#0000ff", -- blue
"#cc00ff", -- purple
}
local colors_hair = {
"#ff0000", -- red
"#ffcc00", -- orange
"#ffff00", -- yellow
"#00ffff", -- cyan
"#0000ff", -- blue
"#ff00ff", -- pink
"#ffffff", -- white
"#000000", -- black
}
local outfit_fox_female = creatures:outfit({
{
textures = {{"mobs_anthro_fox_fur.png"},},
colors = colors_fur,
colors_ratio = 96,
},
{
textures = {{"mobs_anthro_fox_detail.png"},},
},
{
textures = {{"mobs_anthro_fox_eyes.png"},},
colors = colors_eyes,
colors_ratio = 128,
},
{
textures = {{"mobs_anthro_fox_hair.png"},},
colors = colors_hair,
colors_ratio = 192,
},
})MirceaKitsune wrote:Creatures is now the first mob mod for Minetest to support texture overlays and scripted color definitions. A new function lets you define multiple layers in a table, each containing any number of texture sets and colors. The textures and colors are merged into all possible combinations and output to a single table, which is applied directly to the textures field and used by the existing skin system. The magic is done through texture modifiers... specifically "^" to combine the textures, "(" and ")" to separate colored layers in one go, and "^[colorize" to apply the colors. Here's an exact example of such a definition:
MirceaKitsune wrote:Human mobs will now prefer going between man-made objects, such as furnaces / chests / etc. They will also prefer roaming around farmed fields in broad daylight, to do farming :) People will also stick to beds when it is dark. Screenshots of me testing mobs indoor:
Sokomine wrote:That is very good to hear! It ought to allow easy application of clothes, without them having to be treated like armor. That loom from the wardrobe mod may finally be put to gut use! Does it have any effect on connection time? I havn't checked, but I guess the combined textures are generated on the fly by the client when needed?
Sokomine wrote:That's something that'd be very nice for the village inhabitants as well. Right now, my traders just stand around. Can you isolate the behavioural parts so that they may be used in combination with other mods?
local nodes_human = {
-- go to bed if it's dark
{nodes = {"group:bed"},
light_min = 0,
light_max = 7,
objective = "follow",
stay = true,
priority = 0.75,},
-- interact with functional nodes (chests, furnaces, etc) if it's not midday
{nodes = {"default:chest", "default:chest_locked", "default:furnace", "default:furnace_active", "default:sign_wall", "default:bookshelf", "group:door"},
light_min = 7,
light_max = 14,
objective = "follow",
priority = 0.5,},
-- do some farming if it's midday
{nodes = {"group:field"},
light_min = 15,
light_max = 15,
objective = "follow",
priority = 0.5,},
-- wander around idly
{nodes = {"group:crumbly", "group:cracky", "group:choppy"},
light_min = 7,
light_max = 15,
objective = "follow",
priority = 0.1,},
}Users browsing this forum: Google [Bot] and 36 guests