Garry's Mod

Garry's Mod

[E2] Navcore Reworked
57 Comments
meierhans Aug 13 @ 8:49am 
Error on booting up dedicated server:

[Wiremod WARNING]: Operator operator= is now redundant. Ignoring registration. (at line 296) @entities/gmod_wire_expression2/core/custom/navcorereworked.lua
Kerk Jun 9, 2024 @ 3:10pm 
This addon is help me make silly robots. 24 glimbo's gold out of 10.
ByakuyaKuchiki Apr 22, 2023 @ 1:29am 
ah, I didn't have the library
ByakuyaKuchiki Apr 22, 2023 @ 1:26am 
sv: Expression 2 (generic): addons/wire-master/lua/entities/gmod_wire_expression2/core/extloader.lua:387: attempt to index field 'pather' (a nil value)
iNVERTED  [author] Apr 9, 2023 @ 9:03pm 
The old system would result in incomplete, possibly incorrect paths if it couldn't find it within a hard limit of checks. With this system, you can run the navPathStepSimple() multiple times to continue an unfinished pathfind and be guaranteed a valid path if the target isn't in an impossible location.
Mikey Apr 9, 2023 @ 7:43pm 
i feel like you should add back the canPathGenerate() function and add a convar for how long between generations
iNVERTED  [author] Apr 9, 2023 @ 7:21pm 
While a pather is going, navPathAreasChecked() returns how many areas it has checked, and navTotalAreas() returns how many areas the map in all has. It's not possible to know exactly how much is left, only able to estimate it.
Mikey Apr 9, 2023 @ 7:21pm 
i have a custom core that i have made as well, just to make the player move
Mikey Apr 9, 2023 @ 7:21pm 
is it ok if i send an image of my code to you?
Mikey Apr 9, 2023 @ 7:17pm 
also what if i want to return the current progress the step function has made even if the path isnt fully generated?
Mikey Apr 9, 2023 @ 7:16pm 
yea
iNVERTED  [author] Apr 9, 2023 @ 7:14pm 
Minor correction, it would actually return "Complete" not "Success"
Mikey Apr 9, 2023 @ 7:13pm 
i completely forgot about the string return in the step function
Mikey Apr 9, 2023 @ 7:13pm 
you know what you're probably right.
iNVERTED  [author] Apr 9, 2023 @ 7:09pm 
If navPathStepSimple() doesn't return "Success" then navReturnPathSimple() will fail
iNVERTED  [author] Apr 9, 2023 @ 7:08pm 
About the navReturnPathSimple() had the path finished before it was used?
iNVERTED  [author] Apr 9, 2023 @ 7:07pm 
Don't know how the core was completely missing, but should hopefully be fixed now
Mikey Apr 9, 2023 @ 6:44pm 
by you i mean my "bot"
Mikey Apr 9, 2023 @ 6:43pm 
the path generation doesn't reach the destination, it gets stuck nearby or, on gm_construct, on top of the main building, you just keep walking off the edge and going back to the destination over and over
Mikey Apr 9, 2023 @ 6:28pm 
but it lags a lot due to a big path being generated when far away.
Mikey Apr 9, 2023 @ 6:13pm 
i just fixed the problem by setting the max steps to 10000 and using navPathStepSimple(10000)
Mikey Apr 9, 2023 @ 6:12pm 
ok i just figured out that if the path tries to generate more steps than navPathStepSimple() it errors.
Mikey Apr 9, 2023 @ 6:04pm 
it only happens when i use navReturnPathSimple()
Mikey Apr 9, 2023 @ 6:04pm 
attempt to index nil value
Mikey Apr 9, 2023 @ 6:03pm 
error on line 417
Mikey Apr 9, 2023 @ 6:01pm 
but it has the same issues i had before
Mikey Apr 9, 2023 @ 5:56pm 
the github version works
Mikey Apr 9, 2023 @ 5:54pm 
im gonna try using the github version
Mikey Apr 9, 2023 @ 5:35pm 
the mod is not working, the commands arent showing and the extension isn't being loaded.
iNVERTED  [author] Apr 9, 2023 @ 2:46pm 
Rereworked the Pathfinders Library, which should solve various issues with this one.
Bear Mar 3, 2023 @ 11:14am 
Can you make E2 Shield?
Mikey Feb 23, 2023 @ 8:22pm 
and the navPathStepSimple function is just returning "Reached Goal"
Mikey Feb 23, 2023 @ 8:20pm 
so whenever you get too far away from the start of the path generation or go behind a wall or two it errors with "entities/gmod_wire_expression2/core/custom/navcorereworked.lua:347: attempt to index a nil value"
iNVERTED  [author] Dec 28, 2022 @ 5:17pm 
Changes have been made
StrawWagen Dec 27, 2022 @ 9:35pm 
ooo
iNVERTED  [author] Dec 27, 2022 @ 9:09pm 
I've convinced myself to work on this addon again. I've created a new pathfinding base that will allow for splitting up the progress on pathfinding. I've also improved optimization on pathfinding quite a bit, allowing more path generation at once. Changes will be applied fairly soon.
Konstak Nov 8, 2022 @ 1:01pm 
May we have an actual tutorial on how to use this? Like a youtube tutorial or something. i have 0 clue how to even use this even after checking everything. there's no proper tutorial on what to do or how to make something with it and i haven't seen anyone explaining this on yt.
iNVERTED  [author] Aug 8, 2022 @ 5:20pm 
I think I may have an idea on how to accomplish that
StrawWagen Aug 1, 2022 @ 12:46pm 
You think it might be possible to split the pathfinding up between frames?
Allows for longer paths without nuking the session
crazygamerguy10 Jul 1, 2022 @ 1:21pm 
maybe my code is just unoptimized.
crazygamerguy10 Jul 1, 2022 @ 1:20pm 
hmm
iNVERTED  [author] Jul 1, 2022 @ 12:45pm 
I'm not getting any tick quotas on gm_boreas with the E2s I've been testing with
crazygamerguy10 Jun 30, 2022 @ 4:17pm 
rn im on gm_boreas
crazygamerguy10 Jun 30, 2022 @ 4:17pm 
so for whatever reason when i'm on a big map it just tick quotas even when i turn the area check limit really low
crazygamerguy10 Jun 28, 2022 @ 2:01pm 
The "navSetFollowerSize()" is a game changer, the other Navcore would generate points right up against walls if i was around a corner but now my simfphys taxi doesn't get stuck on walls :steamhappy:
crazygamerguy10 Jun 28, 2022 @ 1:57pm 
thanks
crazygamerguy10 Jun 28, 2022 @ 1:57pm 
yea the old navcore wasn't like that so i was confused for a bit until i realized after using the array's count
iNVERTED  [author] Jun 28, 2022 @ 1:57pm 
The array should return in the proper order now
iNVERTED  [author] Jun 28, 2022 @ 1:44pm 
With how A* works, it reconstructs the path from the goal back to the start. I could make it reverse the array before returning.
crazygamerguy10 Jun 28, 2022 @ 1:32pm 
im not sure if thats how its supposed to be or not