nickjanssen / patroljs Goto Github PK
View Code? Open in Web Editor NEWNavigation mesh toolkit for ThreeJS
Home Page: http://nickjanssen.github.io/PatrolJS/demo/demo.html
Navigation mesh toolkit for ThreeJS
Home Page: http://nickjanssen.github.io/PatrolJS/demo/demo.html
Hi,
Thanks for this interesting library.
I have a question: Can the PatrolJS API be used (or adapted) for the navigation of the player itself (not just the NPCs)? It seems to me the relevant data is there in some form to do this.
I am trying to learn how to build a very simple FPS game:
http://spirare.js.org/app/examples/first-person-navmesh/index.html
https://github.com/waldenn/spirare/
The issue I am running into is that I would like to add basic collision detection and walking-through-terrain/buildings, but that the existing physics libraries don't perform at all on my older graphics card. I am hoping there is a bit simpler way to get there. Any pointers welcome.
Thanks,
Waldenn
does this library support having multiple agents that need to avoid colliding with one another?
@nickjanssen @ZackMercury , how to add nodes in straight path.
Can you tell me how to increase node in patrol.js. suppose if turning is path it is taking more nodes(green box) but if path is straight its taking only one node, How to increase nodes in straight path.
If I select long path to move player. Its going in only two nodes, its fine but if any speed breaker or small hills are come between this path player going below the road.
There is possibility of up and down path between 2 points of straight road. On that time I thinking If I add more node player will move smoothly. For better understanding Video
I tried same code for OBJ but not coming
For example if navmesh contains water and ground and character can only go through water with specific item.
Example: navmesh areas in Unity here
https://docs.unity3d.com/560/Documentation/Manual/nav-AreasAndCosts.html
Can I achieve the same in Patroljs?
Hi,
this links is broken:
http://www.ai-blog.net/archives/000152.html
-- Dirk
Is there any way to use PatrolJS with multiple meshes? For example if current position and destination are on different navmeshes. How to find path between two navmeshes? Thanks.
Hi @nickjanssen โ Wanted to give you a heads up that I'm making some updates to PatrolJS for use with A-Frame and more recent JS tooling.
Planned changes:
It's not clear whether PatrolJS is still maintained (i understand time/energy are limited of course), so I've chosen to begin in a new repository. It's not my intention to create a competing library unnecessarily, so please let me know if these are changes you would welcome as PRs here, instead.
Thanks, and nice work!
Hi! Neat package you've written here. :)
I'd like to use PatrolJS on the browser, without necessarily copy/pasting the script into my build. Using Browserify would normally make this easy, but it appears that PatrolJS is relying on typeof module
as an indicator of whether the code is running server-side or not:
if (typeof module !== 'undefined' && module.exports) {
_ = require('underscore');
THREE = require('three');
ProgressBar = require('progress');
}
else {
_ = window._;
THREE = window.THREE;
// stub in the browser
ProgressBar = function () {
return {
tick: function () {}
};
};
}
This isn't really ideal, as the same CommonJS module system can be used for browser-side code. Perhaps detecting process
would be better?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.