jerenaux / phaserquest Goto Github PK
View Code? Open in Web Editor NEWReproduction of Mozilla's BrowserQuest using Phaser, socket.io and Node.js
Home Page: http://www.dynetisgames.com/2017/03/18/phaser-quest/
License: MIT License
Reproduction of Mozilla's BrowserQuest using Phaser, socket.io and Node.js
Home Page: http://www.dynetisgames.com/2017/03/18/phaser-quest/
License: MIT License
I have the server running OK, and the client seems to load. I type in a character and click "new game". But then the game basically locks up on the phrase "Creating World..."
Is there something I have to do to initialize the Mongo DB? I have Mongo DB installed on the default port and everything. I also made sure all the ports were open on the firewall, etc.
Is there any configuration that needs to be done, to get this to run on a particular server install?
Map JSON format has changed in Tiled in versions higher than 1.1.6. Cause of that provided tmx
map in phaserquest
won't be exported to JSON format supported by format
script.
format
script throws an error when formatting JSON map exported from Tiled in versions higher than 1.1.6:
➜ server git:(master) node -e 'require("./format").format()'
Formatting ...
/Users/adamsawicki/Kodowanie/phaserquest/js/server/format.js:62
var tileProperties = map.tilesets[0].tileproperties[layer.data[j]-1];
^
TypeError: Cannot read property '-1' of undefined
at /Users/adamsawicki/Kodowanie/phaserquest/js/server/format.js:62:72
at FSReqCallback.readFileAfterClose [as oncomplete] (internal/fs/read_file_context.js:61:3)
This, in turn, makes running edited map impossible.
Provide information to developers that using Tiled version 1.1.6 or lower is a workaround for the issue.
Modify format
script to the new JSON format.
More details can be found in this thread: https://discourse.mapeditor.org/t/are-old-versions-of-tiled-available/3721/4
Hello,
As you may well know I'm the author of the RPG Mod Branch.
I was wondering do you have the file exports for map editing? I was hoping to polish it a bit and eventually import some of my own maps into the game.
Kind regards,
Josh L.
Thank you so much for this! I've been tinkering with BrowserQuest for a while with limited success. I am going the Docker route. I have PhaserQuest working locally using a docker with an alternative port. When I forward the container, the main page loads but displays a black screen. After investigating, the folder 'assets' and 'socket.io' are trying to be loaded from the main access point, in this case 'pq'. I can access the folders if I put 'pq' in front of the URL but I cannot seem to forward those two folders properly. Do you have any ideas?
Also,there is some lag when moving.
What have I done?
I followed the instructions and ran node server.js.
What happened?
Listening on 8081
(node:934736) [MONGODB DRIVER] Warning: Current Server Discovery and Monitoring engine is deprecated, and will be removed in a future version. To use the new Server Discover and Monitoring engine, pass option { useUnifiedTopology: true } to the MongoClient constructor.
Map read
Connection to db established
connection with ID M1nFdvQFOeBD6vjvAAAA
0 already connected
/home/marek/phaserquest/js/server/GameServer.js:268
GameServer.server.db.collection('players').insertOne(document,function(err){
^
TypeError: GameServer.server.db.collection is not a function
at Object.GameServer.addNewPlayer (/home/marek/phaserquest/js/server/GameServer.js:268:26)
at Socket.<anonymous> (/home/marek/phaserquest/server.js:117:16)
at Socket.emit (events.js:314:20)
at /home/marek/phaserquest/node_modules/socket.io/lib/socket.js:503:12
at processTicksAndRejections (internal/process/task_queues.js:79:11)
Is there a specific tool that we can use to easily edit the sprites JSON and PNG, or are there some kind of atlas format files missing ?
Hello, I need your help, I want to modify
assets\json\db.json;
assets\json\entities_ client.json;
assets\json\entities_ server.json;
assets\sprites\atlas1.json;
But I don't know how to generate this file. Is there any tool or manual modification?
Hey,
Been having some issues with chat messages not being sent through by the server.
So this bit
rooms.forEach(function(room){
socket.broadcast.to(room).emit('chat', {id:playerID,txt:txt});
});
doesn't seem to work for me.
Any ideas?
Listening on 8081
/root/phaserquest/js/server/GameServer.js:686
GameServer.dirtyAOIs.forEach(function(aoi){
^
TypeError: Cannot read property 'forEach' of undefined
at Object.GameServer.clearAOIs (/root/phaserquest/js/server/GameServer.js:686:26)
at Timeout.GameServer.updatePlayers [as _onTimeout] (/root/phaserquest/js/server/GameServer.js:679:16)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
How to fix that?
I've been working with BrowserQuest for a couple years now, and this is something new indeed. I am loving it thus far, though it seems a bit choppy around the edges. Anyway, what is the compatibility with mobile devices? Does this take away from that of the original BQ?
Regardless, I am re-writing BQ from absolute scratch (still maintaining some aspects) and still using the canvas system, and thus far I have improved the rendering tremendously. I encourage you to take a look at my repository :)
It seems when grass layer is deleted, character would be displayed on above tiles which it shouldn't (e.g. house roofs, top of trees).
(However I can only reproduce it from my own tmx file)
** Update **
I think this has something to do withnbGroundLayers
being 4. I changed it to 1 (to suit my need) and things works now. Not sure how to properly fix this though. I don't see a similar 4
in browserQuest source code. Why is it necessary here?
Inspecting the original tmx file its map file width is 16px.
However the new tmx file in phaserquest is different, being 32px.
When my 16px grid map is run under phasequest, things are displayed 1/4 the size:
Changing the grid size didn't enlarge things. Is there something I need to do?
Thanks for your great job. I am very interesting PQ, wanna run ASAP.
BTW, I faced error when I start server.
[root@localhost]# node server.js
Listening on 8081
/home/neoguru/html/pq_test/js/server/GameServer.js:84
Object.assign(GameServer.db.entities,GameServer.db.client_entities); // me
^
TypeError: Object function Object() { [native code] } has no method 'assign'
at Object.GameServer.readMap (/home/neoguru/html/pq_test/js/server/GameServer.js:84:12)
at Server.io.on.socket.pings (/home/neoguru/html/pq_test/server.js:85:8)
at Server.g (events.js:180:16)
at Server.emit (events.js:92:17)
at net.js:1056:10
at process._tickCallback (node.js:458:13)
at Function.Module.runMain (module.js:499:11)
at startup (node.js:119:16)
at node.js:945:3
I am not fix mongoDB yet. Do I have to set it first?
Hi there, I would first like to apologize since this is not exactly an issue. But I really want to create an offline version of Phaserquest with some scope update to make the game smaller as I would just like an RPG game that takes around 1-2 hours to finish to teach my brother some concepts through gamification. I was just wondering how feasible would it be to do this? I would like to add some new npcs with the sprites from BQ and also a quest system as well. Thank you!
I respawned on an object where I couldn't walk on, so I was pretty much stuck. Not sure where it was again.
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.