rheo reports: fast-flying through a few doze ... #2421

Closed
opened 2022-08-08 00:08:52 +00:00 by yourland-report · 6 comments

rheo reports a bug:

fast-flying through a few dozen mapblocks full of unloaded birds caused a really significant lag spike

Player position:

{
	y = 20.389999389648,
	z = 3106.1970214844,
	x = 2622.0981445313
}

Player look:

{
	y = -0.30868500471115,
	z = 0.63125479221344,
	x = 0.71149903535843
}

Player information:

{
	formspec_version = 6,
	lang_code = "",
	major = 5,
	minor = 6,
	version_string = "5.6.0",
	state = "Active",
	ip_version = 6,
	min_rtt = 0.15700000524521,
	max_rtt = 4.1500000953674,
	avg_rtt = 0.16500000655651,
	min_jitter = 0,
	max_jitter = 3.9620001316071,
	avg_jitter = 0.00099998712539673,
	connection_uptime = 1634,
	serialization_version = 29,
	patch = 0,
	protocol_version = 40
}

Player meta:

{
	fields = {
		["ocean_build.last_warning"] = "1.6588e+09",
		["stamina:level"] = "0",
		["ocean_build.ocean_built"] = "2",
		["stamina:poisoned"] = "no",
		yl_church = "return {[\"last_death\"] = {[\"y\"] = 15, [\"x\"] = 1353, [\"z\"] = 1089}}",
		punch_count = "861",
		jointime = "1644205752",
		bitten = "0",
		arenalib_infobox_arenaID = "0",
		repellant = "0",
		["ethereal:fly_timer"] = "-99",
		["unified_inventory:bags"] = "return {\"unified_inventory:bag_large\", [4] = \"unified_inventory:bag_large\"}",
		["3d_armor_inventory"] = "return {\"nether_mobs:dragon_boots 1 10800\", \"\", \"\", \"\", \"\", \"\"}",
		xp = "0",
		yl_commons_thankyou = "21",
		inflicted_damage = "143494",
		["signslib:pos"] = "(2056,15,1116)",
		played_time = "1445709",
		digged_nodes = "5630",
		placed_nodes = "13094",
		died = "2",
		crafted = "249",
		yl_commons_player_joined = "1659915722",
		yl_commons_player_created = "1644205752",
		hud_state = "off",
		["stamina:exhaustion"] = "54",
		partychat = "party"
	}
}

Log identifier


[MOD] yl_report log identifier = WZFt4A0QU1RpT0bX3XvseS8ldZiJr0k6

Profiler save:

profile-20220808T000851.json_prettyEE

Status:

# Server: version: 5.5.1-yl | game: Minetest Game | uptime: 7d 21h 11min 40s | max lag: 1.58s | clients: Angra, Chache, Ghitah, rheo, Cody, Codyna, dragon014, AliasAlreadyTaken, Sokomine, Service, Papi, Coolstorms, AspireMint, EvrenW, daydream, LeetPeet, Brebish, icecreamkek

Teleport command:

/teleport xyz 2622 20 3106

Compass command:

/give_compass Construction WZFt4A0QU1RpT0bX3XvseS8ldZiJr0k6 D2691E 2622 20 3106
rheo reports a bug: > fast-flying through a few dozen mapblocks full of unloaded birds caused a really significant lag spike Player position: ``` { y = 20.389999389648, z = 3106.1970214844, x = 2622.0981445313 } ``` Player look: ``` { y = -0.30868500471115, z = 0.63125479221344, x = 0.71149903535843 } ``` Player information: ``` { formspec_version = 6, lang_code = "", major = 5, minor = 6, version_string = "5.6.0", state = "Active", ip_version = 6, min_rtt = 0.15700000524521, max_rtt = 4.1500000953674, avg_rtt = 0.16500000655651, min_jitter = 0, max_jitter = 3.9620001316071, avg_jitter = 0.00099998712539673, connection_uptime = 1634, serialization_version = 29, patch = 0, protocol_version = 40 } ``` Player meta: ``` { fields = { ["ocean_build.last_warning"] = "1.6588e+09", ["stamina:level"] = "0", ["ocean_build.ocean_built"] = "2", ["stamina:poisoned"] = "no", yl_church = "return {[\"last_death\"] = {[\"y\"] = 15, [\"x\"] = 1353, [\"z\"] = 1089}}", punch_count = "861", jointime = "1644205752", bitten = "0", arenalib_infobox_arenaID = "0", repellant = "0", ["ethereal:fly_timer"] = "-99", ["unified_inventory:bags"] = "return {\"unified_inventory:bag_large\", [4] = \"unified_inventory:bag_large\"}", ["3d_armor_inventory"] = "return {\"nether_mobs:dragon_boots 1 10800\", \"\", \"\", \"\", \"\", \"\"}", xp = "0", yl_commons_thankyou = "21", inflicted_damage = "143494", ["signslib:pos"] = "(2056,15,1116)", played_time = "1445709", digged_nodes = "5630", placed_nodes = "13094", died = "2", crafted = "249", yl_commons_player_joined = "1659915722", yl_commons_player_created = "1644205752", hud_state = "off", ["stamina:exhaustion"] = "54", partychat = "party" } } ``` Log identifier ``` [MOD] yl_report log identifier = WZFt4A0QU1RpT0bX3XvseS8ldZiJr0k6 ``` Profiler save: ``` profile-20220808T000851.json_prettyEE ``` Status: ``` # Server: version: 5.5.1-yl | game: Minetest Game | uptime: 7d 21h 11min 40s | max lag: 1.58s | clients: Angra, Chache, Ghitah, rheo, Cody, Codyna, dragon014, AliasAlreadyTaken, Sokomine, Service, Papi, Coolstorms, AspireMint, EvrenW, daydream, LeetPeet, Brebish, icecreamkek ``` Teleport command: ``` /teleport xyz 2622 20 3106 ``` Compass command: ``` /give_compass Construction WZFt4A0QU1RpT0bX3XvseS8ldZiJr0k6 D2691E 2622 20 3106 ```
AliasAlreadyTaken was assigned by yourland-report 2022-08-08 00:08:52 +00:00
flux added the
1. kind/enhancement
3. source/lag
2. prio/interesting
labels 2022-08-08 02:02:19 +00:00
flux added this to the flux's TODO list project 2022-08-08 02:02:44 +00:00
AliasAlreadyTaken was unassigned by flux 2022-08-08 02:02:49 +00:00
flux self-assigned this 2022-08-08 02:02:50 +00:00
Member

in my new mob API, i will encourage that un-tamed mobs will disappear after being being reloaded a couple times. some mobs may want to never static-save when they are untamed, some may want to never disappear.

but stuff that flies really needs to have rules to constrain the number which can spawn and unload into neighboring areas.

in my new mob API, i will encourage that un-tamed mobs will disappear after being being reloaded a couple times. some mobs may want to never static-save when they are untamed, some may want to never disappear. but stuff that flies really needs to have rules to constrain the number which can spawn and unload into neighboring areas.
Member

upstream: mobs shouldn't be able to "walk" into neighboring areas and unload; they should be forced back to where they came from

upstream: mobs shouldn't be able to "walk" into neighboring areas and unload; they should be forced back to where they came from

If its meant to be an API, then those using the API should decide on how or when things disappear. There may be use cases where the game requires taming at all doesn't exist.

Same goes for the "hit the border" problem. There might be usecases for instant despawn, emerging the destination mapblock, serializing or any other action.

Maybe we should write a spec first, I assume the mob api is not intended exclusively for YL but for a general audience :D

If its meant to be an API, then those using the API should decide on how or when things disappear. There may be use cases where the game requires taming at all doesn't exist. Same goes for the "hit the border" problem. There might be usecases for instant despawn, emerging the destination mapblock, serializing or any other action. Maybe we should write a spec first, I assume the mob api is not intended exclusively for YL but for a general audience :D
Member

Same goes for the "hit the border" problem. There might be usecases for instant despawn, emerging the destination mapblock, serializing or any other action.

currently, there is nothing in the lua API that can prevent entities from being unloaded when the engine decides they should be.

you can't even prevent them from walking (or flying) into an unloaded area programmatically. you can only give them a velocity and a direction. you can't say "stop walking once you reach point X". you can, of course, check the position once every server step, but if there's a lag spike, the mob may be in a much different location than it was on the previous step, particularly for fast animals like the water_life birds.

> Same goes for the "hit the border" problem. There might be usecases for instant despawn, emerging the destination mapblock, serializing or any other action. currently, there is nothing in the lua API that can prevent entities from being unloaded when the engine decides they should be. you can't even *prevent* them from walking (or flying) into an unloaded area programmatically. you can only give them a velocity and a direction. you can't say "stop walking once you reach point X". you can, of course, check the position once every server step, but if there's a lag spike, the mob may be in a *much* different location than it was on the previous step, particularly for fast animals like the `water_life` birds.
Member

If its meant to be an API, then those using the API should decide on how or when things disappear.

yeah, i suppose i shouldn't have said the API. when i meant, when i get around to actually re-implementing various mobs in the new API.

also, after i wrote this, i had two other ideas that are perhaps preferable to "no staticsave at all"

  • perhaps "wild" mobs should only be reloaded a fixed number of times
  • perhaps "wild" mobs would have a lifetime bound to IRL time, not the amount of time they are actually loaded in-game. if something flies out of bounds, you should be able to run after it and find it again.

also, things like the balrog and the mime clearly need to be effectively immortal (don't despawn) or they're not as fun.

> If its meant to be an API, then those using the API should decide on how or when things disappear. yeah, i suppose i shouldn't have said the API. when i meant, when i get around to actually re-implementing various mobs in the new API. also, after i wrote this, i had two other ideas that are perhaps preferable to "no staticsave at all" * perhaps "wild" mobs should only be reloaded a fixed number of times * perhaps "wild" mobs would have a lifetime bound to IRL time, not the amount of time they are actually loaded in-game. if something flies out of bounds, you should be able to run after it and find it again. also, things like the balrog and the mime clearly need to be effectively immortal (don't despawn) or they're not as fun.
flux added the
4. step/at work
label 2022-10-20 16:13:08 +00:00
Member

closing this as a dupe of #2077

closing this as a dupe of #2077
flux closed this issue 2023-01-06 23:47:08 +00:00
flux added
5. result/duplicate
and removed
4. step/at work
labels 2023-01-06 23:47:21 +00:00
flux removed this from the flux's TODO list project 2023-01-06 23:47:23 +00:00
flux removed their assignment 2023-01-06 23:47:26 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: your-land/bugtracker#2421
No description provided.