Computer Science Project

New to the site?

Computer Science Project

Postby Thaywood » Fri Jun 17, 2016 10:57 am

I am a student trying to find some advise, i am currently developing a game for a course work project. The info below are what i plan to add however i was wondering if there is any thing more complex to add as the project does need to be quite complex. A* or Dijkstra shortest path are currently in use but preferably algorithms that for NPC, quests, and monsters (battle) in game, any advise will be greatly appreciated.

(Multiplayer Role Playing Game/quests & battle/2D)
Including: HTML, CSS, JavaScript, Node.js, MySQL

Complexity
A* Pathfinding {moving player around area}
Relational Database {storing player stats, items, quests}
Sharing data over LAN/internet {allow multiple players to play live at same time}
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Computer Science Project

Postby hallsofvallhalla » Fri Jun 17, 2016 12:21 pm

I am not sure what exactly you are asking but also remember all the algorithms for battle, level up, items, ect.. That balance in itself can be very difficult. Decide where your code lies, server or client and if you are using Nodejs should you use MongoDB instead of MySQL. Also I am sure you will be using Socket.io as well.
User avatar
hallsofvallhalla
Site Admin
 
Posts: 11750
Images: 13
Joined: Wed Apr 22, 2009 6:29 pm
Location: mobile, al
Has thanked: 11 times
Been thanked: 141 times
Blog: View Blog (3)

Re: Computer Science Project

Postby Thaywood » Fri Jun 17, 2016 12:43 pm

Thanks for the reply and the advice of the mongoDB i have made prototype using node.js and socket.io. I am trying to make the code mainly server side to be more secure. How would you recommend to store the player storage within the database eg for items and quests, as separate fields or as a long string and separating the string into an array by splitting. Let me know what you think?
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Computer Science Project

Postby a_bertrand » Fri Jun 17, 2016 12:48 pm

If you are in AI development, then I would look how to handle hordes, and not single entities.
Creator of Dot World Maker
Mad programmer and annoying composer
User avatar
a_bertrand
New Worlds Engine creator
 
Posts: 1499
Joined: Mon Feb 25, 2013 8:46 am
Has thanked: 15 times
Been thanked: 21 times

Re: Computer Science Project

Postby Thaywood » Fri Jun 17, 2016 12:51 pm

I am hoping to have something like hordes in the game as they will be free roaming round the map. Do you have any ideas of where to start?
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Computer Science Project

Postby hallsofvallhalla » Fri Jun 17, 2016 1:03 pm

If you use Mongo then just create a class or rather a item object then you can store the whole object without much overhead. Same with nearly everything else. I have not found a good Nodejs to MySQL lib so I am not sure on that one.
User avatar
hallsofvallhalla
Site Admin
 
Posts: 11750
Images: 13
Joined: Wed Apr 22, 2009 6:29 pm
Location: mobile, al
Has thanked: 11 times
Been thanked: 141 times
Blog: View Blog (3)

Re: Computer Science Project

Postby Thaywood » Fri Jun 17, 2016 1:48 pm

Thanks for the help about the class. Well i am using c9.io to run the game while i develop it, i may think a battle in a screen like the classic RPG style will be best and easily under stood by many. What do you think is it worth sticking with the RPG style battle or change to a different battle system? Any ideas? I was thinking of an idea where there the player looks left and right to find any monsters before entering a new area. What do you think about this? I just thought make it slightly different compared to other games but not too different.
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Computer Science Project

Postby Thaywood » Mon Jun 27, 2016 6:31 am

Hi again,
i am trying to implement the moving of the player in game using A* pathfinding, do you have any advise on storing the grid locations in the game area where the player is standing. I currently have it as an array, of 0 and 1, however i feel this is very inefficient as storing this will take allot of space. Would storing in a database be quicker, or storing it on the server, or client (however this could lead to some hacking to be able to move on non-moving placeholders.)
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Computer Science Project

Postby a_bertrand » Mon Jun 27, 2016 8:25 am

A* algorithm is pretty simple to work with a grid, but you could work just with a list of "blocking" points if you feel that it takes too much resources. The other solution is that instead of moving in "pixel" you move in "cells" while a cell is multiple pixels so for example if a cell is 32x32 pixels, you will have 32x32 less cells in your grid ;)
Creator of Dot World Maker
Mad programmer and annoying composer
User avatar
a_bertrand
New Worlds Engine creator
 
Posts: 1499
Joined: Mon Feb 25, 2013 8:46 am
Has thanked: 15 times
Been thanked: 21 times

Re: Computer Science Project

Postby Thaywood » Wed Jun 29, 2016 5:46 am

Would you recommend storing this grid as array on the server of node.js. Or would you store it in a database?
Thaywood
 
Posts: 17
Joined: Fri May 01, 2015 3:36 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to Say Hello

Who is online

Users browsing this forum: No registered users and 1 guest

cron

x