I had the idea to improve the monster (and npc) movement. Currently they can only walk up and down or left and right. It they come to an obstacle they stop.
Its not easy to decide how they should move. So I would like to ask you.
1) Perhaps only add diagonal movement
2) add some walk around obstacle code
3) combine straight and diagonal movement
4) your idea here
v0.8.10 (BWM fill) released to Google Play!
Useful links
Source code of the game - Contribution guide - ATCS Editor - Translate the game on Weblate - Example walkthrough - Andor's Trail Directory - Join the Discord
Get the game (v0.8.10) from Google, F-Droid, our server, or itch.io
Useful links
Source code of the game - Contribution guide - ATCS Editor - Translate the game on Weblate - Example walkthrough - Andor's Trail Directory - Join the Discord
Get the game (v0.8.10) from Google, F-Droid, our server, or itch.io
improve monster movement
-
- VIP
- Posts: 655
- Joined: Wed Feb 23, 2011 3:35 pm
- android_version: 2.2
improve monster movement
Level: 101, XP: 18780586, Gold: 358739
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
-
- Posts: 39
- Joined: Wed Jul 06, 2011 5:33 am
Re: improve monster movement
Is it possible to apply agro? So they come to us, like certain mobs. And then some try and run away?
-
- Posts: 29
- Joined: Tue Jul 12, 2011 12:40 pm
- android_version: 2.2
- Location: Florida
Re: improve monster movement
Dig for some underground creature would be a nice touch.
Lvl: 22, XP: 203608, Gold: 3601, RoLS: 0, ElyR: 0, RoL: 0
HP: 55, AC: 142%, AD: 15, AP: 2, CC: -, CM: -, BC: 24%, DR: -
Lvl: 22, XP: 193313, Gold: 7046, RoLS: 0, ElyR: 0, RoL: 0
HP: 75, AC: 122%, AD: 12, AP: 3, CC: -, CM: -, BC: 49%, DR: -
HP: 55, AC: 142%, AD: 15, AP: 2, CC: -, CM: -, BC: 24%, DR: -
Lvl: 22, XP: 193313, Gold: 7046, RoLS: 0, ElyR: 0, RoL: 0
HP: 75, AC: 122%, AD: 12, AP: 3, CC: -, CM: -, BC: 49%, DR: -
-
- VIP
- Posts: 655
- Joined: Wed Feb 23, 2011 3:35 pm
- android_version: 2.2
Re: improve monster movement
This is a good idea, but it is limited by the monster areas. Monsters have an area they cannot exit.kendraso wrote:Is it possible to apply agro? So they come to us, like certain mobs. And then some try and run away?
Perhaps aggressive monsters could go towards the player if he enters their area and cowards would flee when he enters.
This should be randomized otherwise it would be look like this:
Code: Select all
cccc......a
ccc......aa
cc......aaa
c......aaaP
You mean they would pop up if the player is on one of the adjacent fields?Countvlad54 wrote:Dig for some underground creature would be a nice touch.
Level: 101, XP: 18780586, Gold: 358739
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
-
- Posts: 29
- Joined: Tue Jul 12, 2011 12:40 pm
- android_version: 2.2
- Location: Florida
Re: improve monster movement
Yea, something like that, maybe young wyrms could do that.
Lvl: 22, XP: 203608, Gold: 3601, RoLS: 0, ElyR: 0, RoL: 0
HP: 55, AC: 142%, AD: 15, AP: 2, CC: -, CM: -, BC: 24%, DR: -
Lvl: 22, XP: 193313, Gold: 7046, RoLS: 0, ElyR: 0, RoL: 0
HP: 75, AC: 122%, AD: 12, AP: 3, CC: -, CM: -, BC: 49%, DR: -
HP: 55, AC: 142%, AD: 15, AP: 2, CC: -, CM: -, BC: 24%, DR: -
Lvl: 22, XP: 193313, Gold: 7046, RoLS: 0, ElyR: 0, RoL: 0
HP: 75, AC: 122%, AD: 12, AP: 3, CC: -, CM: -, BC: 49%, DR: -
-
- Posts: 49
- Joined: Sun Mar 06, 2011 6:22 pm
Re: improve monster movement
I think i would be also nice, if someone could set up movement animations, at least for the player.
/Michi... can be found at STEAM!
- qTzal
- Posts: 36
- Joined: Tue Dec 27, 2011 7:41 am
- android_version: 9.0 - Pie
Re: improve monster movement
On making monsters work different/better:
ignoring for a minute the work involved -
How much of a burden would it add to the overall program storage size, running memory usage and run speed/lag time for monster handling to done outside the maps?
In this manner monsters would not be tied to a defined spot and could be given more realistic(fun) behaviors.
ignoring for a minute the work involved -
How much of a burden would it add to the overall program storage size, running memory usage and run speed/lag time for monster handling to done outside the maps?
In this manner monsters would not be tied to a defined spot and could be given more realistic(fun) behaviors.
-
- VIP
- Posts: 655
- Joined: Wed Feb 23, 2011 3:35 pm
- android_version: 2.2
Re: improve monster movement
IMO too much.qTzal wrote:On making monsters work different/better:
ignoring for a minute the work involved -
How much of a burden would it add to the overall program storage size, running memory usage and run speed/lag time for monster handling to done outside the maps?
In this manner monsters would not be tied to a defined spot and could be given more realistic(fun) behaviors.
a) memory: You would need every map available in memory. (to know where monsters can go and where are obstacles [tiles would not be needed, this would be a no go.])
b) running speed: We currently have 280 maps with around 10 to 20 monsters on each of it. I think the world will get up to 750 - 1500 maps.
So we will need to calculate over 10000 movements each second. (thats not very much, but the worse thing about it is: it needs random access to the map obstacles which will probably slow it down because of paging)
c) If in addition to (b) the movement code would need some adjustments (like chasing or something like this) then lag will come for sure.
I fear we will loose the slow phones from it.
Level: 101, XP: 18780586, Gold: 358739
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
HP: 398, AC: 303%, AD: 84-95, AP: 4, ECC: 12, CM: -, BC: 13%, DR: 0
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 2, VSH: 1, WMC: 0, GoW: 0
- qTzal
- Posts: 36
- Joined: Tue Dec 27, 2011 7:41 am
- android_version: 9.0 - Pie
Re: improve monster movement
Ok, so I'll admit to prior experience programing (C, C++, pascal, basic, VB, assembler) and that I really wasn't thinking that big. No where near that big.Samuel wrote:a) memory: You would need every map available in memory. (to know where monsters can go and where are obstacles [tiles would not be needed, this would be a no go.])
There are maps and there are monsters native to that map. Monsters would not be able to follow the PC off one map to another; maybe you could make an exception for quest monsters - I don't see the need.
You could have a 3 minute countdown timer for a for recently accessed map; within that time an out of view map would only generate requests for respawns. If the PC re-enters within the timer countdown all the original monsters left behind plus any respawns would be placed on the map in randomized positions. We all know that after gamers video game monsters have the shortest attention span. There is no reason to expect the monsters will remember to hang around the exit waiting for you to return.
After the timer has elapsed the map resets to defaults, same as it is currently handled. Once the map resets it doesn't need to be in memory.
True. I would expect that active monster positioning only needs to be calculated on the map that is currently occupied: see my attention span crack above.Samuel wrote:b) running speed: We currently have 280 maps with around 10 to 20 monsters on each of it. I think the world will get up to 750 - 1500 maps.
So we will need to calculate over 10000 movements each second. (thats not very much, but the worse thing about it is: it needs random access to the map obstacles which will probably slow it down because of paging)
No doubt.Samuel wrote:c) If in addition to (b) the movement code would need some adjustments (like chasing or something like this) then lag will come for sure.
In addition to point c) I see a schism forming in development paths that lean towards a more authentic "Rougelike" experience or a "Gold Box" Pools of Radiance like experience. Andor's Trail definitely looks like it could easily move towards a Gold Box level playing experience, especially when phones about as slow as my Droid 1 die off.Samuel wrote:I fear we will loose the slow phones from it.
I don't imagine that even quad core tablets are going to be up to a Baldur's Gate level of game play.
Maybe if someone comes up with a "uWoW" ...
-
- Posts: 121
- Joined: Sun Oct 16, 2011 8:40 am
- android_version: 2.2
Re: improve monster movement
You could also limit the type of monsters that could move through a larger area and also through which areas they can move (for example those giant wasps seem like they could be able to move through the entire area where the trees have been cut down, but no reason for them to go beyond, frogs on the other hand don't seem very mobile creatures and could probably stick to one map). In addition you would only have monsters move around on maps within quick reach of the player, so let's say 8 extra maps if you want to go 1 deep or 16 extra maps if you want to go 2 deep (most of the time it will be less as rarely there's another accessible map on each side of the current map). There's absolutely no need to be thinking about the entire game world to simulate larger monster movement.
The game is fine as it is though, but it would be nice to come across an unexpected monster here and there. Maybe alternatively maps can have a small chance of spawning a monster that is usually found on a neighbouring map? It feels a bit like a 'cheat' but it will get around the whole monster movement headache. You could even place spawning points for this near the exit towards that other map so the monster actually appears to be coming from that map.
The game is fine as it is though, but it would be nice to come across an unexpected monster here and there. Maybe alternatively maps can have a small chance of spawning a monster that is usually found on a neighbouring map? It feels a bit like a 'cheat' but it will get around the whole monster movement headache. You could even place spawning points for this near the exit towards that other map so the monster actually appears to be coming from that map.
Lvl: 195, XP: 135178554, Gold: 1004501
HP: 88 AC: 345%, AD: 109-120, AP: 5, ECC: 15%, CM: 0, BC: 222%, DR: 6
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 1, VSH: 2, WMC: 0, GoW: 0
HP: 88 AC: 345%, AD: 109-120, AP: 5, ECC: 15%, CM: 0, BC: 222%, DR: 6
RoLS: 2, ElyR: 1, RoL: 1, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 1, VSH: 2, WMC: 0, GoW: 0