0

Hi there

I've had a bee in my bonnet for a little while now and I've decided to get the ball rolling on creating my own web-based RPG game. But I'm not sure what the best route is with a programming language. I have some basic php knowledge and I've tried to find some sources regarding the best language to use but nothing has stood out predominantly. I know PHP does all the work server-side and I'm thinking that it might not work well if the server has a lot of people playing the game.

Any advice would be greatly appreciated.

11
Contributors
20
Replies
21
Views
9 Years
Discussion Span
Last Post by PirateTUX
0

First thing you need to figure out is how the RPG will work online. Realtime? Turn-based? Are we talking text-based or will it have 2D scrolling maps? Think about the design and what you want it to turn out as, then decide which language would be more suitable, as 'rpg' can be such a broad range of games.

0

Hi Phaelax

The game will be text-based. No real time functionality. There will be turn-based functionality whereby a player will have x amount of time to retaliate (e.g 30mins). The game will be a fantasy one where each player has their own character. Essentially I'd like to create a pvp(player versus player) and pve(player versus enviroment) enviroment text-based game. Can you give me an idea of what languages would be good for certain situations regarding functionality.

0

My guess would be that C++ would be your best bet for just about anything as far as text-based games goes, although that's a matter of one noobie's opinion ;). I remember playing around with something called WinSock that allowed connections to be made between two computers (maybe more than 2 but I'm not sure) over a LAN or the internet. If you've never done any C++ programming it would take some time and effort to learn the basics before anything else, but a text-based game is a fairly easy learning project.

Below is a link to a RockPaperScissors game that uses WinSock. It is already compiled but the source is included as well. There are two main parts: a server, and a client. The only thing I ever changed was the images because the originals were a disgrace...

RPSWinsock
Right Click, Save Link As...

Good Luck

0

I've only been using ASP.NET mostly for web apps and there are some great things coming out of AJAX. One of the cool things about AJAX is that it allows you to set a portion of the web page to update without having to refresh the entire web page. This is helpful when connecting to several databases because everytime someone refreshes a page they have to request all that data again. It helps keep transactions in the database lower. You will also want to learn about OOP (Object Oriented Programming). Java is a good language for that. Also I did mention databases and you will need some way of storing character stats when they are offline.

0

Thanks for the responses. I do have some MySQL knowledge that I could use. Didn't realise C++ was used for web. Guess you learn something new every day.

0

I may be wrong but I've never heard of C++ being used for the web. Unless its for some web app DLLs and not server side scripting. C# would be something you'd use, which isn't a variation of C or C++. I've heard from other developers that C# is a Java clone. Anyway C++ can't be used for the web in the sense of PHP, Java or C#.

0

This web game of mine is going to be purely text based so I don't think I'll need to go as far as using C# or Java unless it can be used to process things from and to a MySQL database faster than PHP would.

Ajax sounds like a good option, I've herd a few good things about it. I'll definitely look into that.

0

I may be wrong but I've never heard of C++ being used for the web. Unless its for some web app DLLs and not server side scripting. C# would be something you'd use, which isn't a variation of C or C++. I've heard from other developers that C# is a Java clone. Anyway C++ can't be used for the web in the sense of PHP, Java or C#.

Many CGI scripts are written entirely in C++.

As for AJAX, you can't use AJAX entirely since there's no real constructs to interact with a database. You'll need some type of server-side language (CGI/PHP/Ruby on Rails/etc.)

0

I agree that AJAX alone isn't for database access, but ASP.NET + AJAX makes for some great interactive online forms to work with databases.

Many CGI scripts are written entirely in C++.

ShawnCplus, you are correct about using C++ for CGI. Whenever the name CGI popped up, I first think of Perl and never C++.

0

Nice responses guys, since I know some php I think I'll stick to it and dive into AJAX. Definitely seems to be the solution to lifting the load off the server.

If you guys have anything else to add don't hesitate to do so.

0

Unless its for some web app DLLs and not server side scripting.

That is exactly right... Winsock is a windows API that can be used in C++ which allows sending/receiving information through sockets. If one wishes to create a fully interactive server for an RPG C++ probably isn't the best choice (I was thinking more of using it to program the RPG client itself, not the server).

Good Luck,
-Dan

0

If you are looking for a easy interface program that requires little of no programming knowladge go for gameweaver. Its a little pricey but is definately worth every penny.

0

Since you're planning on having this be text based w/o a turn system I'd use either C++ or PHP. You can have PHP work in a live environment with seemless refreshes, but it's difficult to do.

C++ is designed better for this type of thing, but PHP is based off of C++ so there's a pretty good chance that it could work.

I'd try them both, and see what one you like better. I know that's a lot of work, but that's what Alpha and Beta testing is for.

Good luck, man (^_^)

0

Since you're planning on having this be text based w/o a turn system I'd use either C++ or PHP. You can have PHP work in a live environment with seemless refreshes, but it's difficult to do.

C++ is designed better for this type of thing, but PHP is based off of C++ so there's a pretty good chance that it could work.

I'd try them both, and see what one you like better. I know that's a lot of work, but that's what Alpha and Beta testing is for.

Good luck, man (^_^)

Thanks Suetan. I'll definitely look into compatibility between the two.

0

My guess would be that C++ would be your best bet for just about anything as far as text-based games goes, although that's a matter of one noobie's opinion ;). I remember playing around with something called WinSock that allowed connections to be made between two computers (maybe more than 2 but I'm not sure) over a LAN or the internet. If you've never done any C++ programming it would take some time and effort to learn the basics before anything else, but a text-based game is a fairly easy learning project.

Below is a link to a RockPaperScissors game that uses WinSock. It is already compiled but the source is included as well. There are two main parts: a server, and a client. The only thing I ever changed was the images because the originals were a disgrace...

RPSWinsock
Right Click, Save Link As...

Good Luck

c++ can be used for internet things too? i thought it was designed and using for heavy duty applications and things that where highly complex.

0

Just about any language can be used, although some languages are more/less suitable for various reasons. C++ can be used for web applications quite comfortably, when coupled with a database and perhaps XML parsing libraries ( + other libraries as appropriate ).

Big web applications are pretty heavy-duty/high-load, and complicated.

As far as I know, the PHP interprettor is written in C++, so really, when you write/run a PHP app, you're just providing very detailed instructions to a C++ application. Same goes for Perl: it's interpretted by a program written in C(++?). Other languages are different, though.

0

I've got a good friend who wrote a web-based MMO completely in PHP using MySQL as his data storage method. That's probably the route that I would take were I to give it a shot.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.