Jump to content
xisto Community
Leveecius

A Little Bit Of Help For Me Please!

Recommended Posts

Hey guys, I've looked at a LOT of different places and can't really find the help I need. I'm looking for some input or someone who is actually willing to help me in the Creation of my online multiplayer text based RPG. My game will be something like torncity, or global-syndicate (for those who know those), only with slight differences and changes that I have thought of. The game itself really isn't going to be that hard to design really, it's the factors and timing and stuff like that I'm not too good at. I know I'm going to need a database (MySQL), and know some good scripting which is fine with me, I'm descent with C++ scripting, but rusty at it. It's been almost 8 years since I've done it! :rolleyes: . But now for my situation. I'm looking for something or someone to help me with my databasing. I'm sure you all have played, if not at least seen a text-based RPG, so if any of you may be able to help me out any please let me know.Also I'm trying to learn PHP right now too, so that helps

Edited by Leveecius (see edit history)

Share this post


Link to post
Share on other sites

Oh, and I can do HTML and XHTML scripting, and I'm pretty good at it. I've been learning PHP like I stated earlier, and see it's a LOT like HTML, only with addons, so I'm sure it won't be TOO hard to learn. But here is my question that I'm really hoping to have answered.Like most RPG's you will have stats based on EXP, and stuff like that, but how would you go about implementing those stats into certain variables that give random results? For example, lets say you have 25 power, 30 defense, and a weapon that gives you +10 attack and +15 defense, and you do a job that requires X stamina to do, and the payout is between X and X amount of dollars, but the collateral damage is X depending on your stats? You know what I mean? Basically that's where I'm having the most problems right now. Everything else on the site I can pretty much do. As far as like hourly income, and stats for items/properties and stuff like that, I just don't know how to incorporate the stats into the rest of the sites data base. Think anyone can help me any?

Share this post


Link to post
Share on other sites

There are a couple of open source web game engines that you could use easily for this type of game if a web game copy is what you were considering making. I cannot think of any of them off the top of my head, but a quick google will find them for you "open source php web game engine" Web games have become a dime a dozen, with very little difference between them, as most are using the same basic templates with different graphics and slight modifications to the story. What does your game design have that will set it apart from all the others in the same genera? Also do you have experience with php and mysql, as php is the language most of these games are written in and if you want to make a game that will be different from anything else out there you will need to do a lot of programming.I know this usually becomes the standard reply to anyone who is trying to make a game, but there is a lot to be said for it, and that sometimes it is better to join an existing project to get a feel for how all these things work and to learn as much as you can before venturing off to attempt to do something that is over your head and outside your current level of skills. There are lots of projects out there that are looking for team members that will be able to teach you a lot of what you will need to know about php and mysql among other things.

Edited by The_Fury (see edit history)

Share this post


Link to post
Share on other sites

I do have exp. with PHP, but not with MySQL. My Exp is limited with the PHP tho, I spent more time learning HTML and XHTML scripting. As for the differences, my game is more user interacting with other users, and ranking is different (basically ranks are not automatically given), and there are other features that set it apart. Like I said, it will have the same basic principle as torncity, but more like global-syndicate. It follows a LOT of the same outlines, just a few add-ons and differences with mine, that's all, something to keep people a little more entertained.

Share this post


Link to post
Share on other sites

It is easy to create a text based game, i learnt how to do it in less than 1 week. You just have to be patient, a few sites that helped me and iam sure will help you are

http://www.tizag.com/phpT/syntax.php <-- basic PHP + MYSQL
http://www.maketemplate.com/ <-- CSS training
http://www.w3schools.com/PHP/php_ajax_intro.asp <-- advanced PHP + MYSQL

Like most RPG's you will have stats based on EXP, and stuff like that, but how would you go about implementing those stats into certain variables that give random results? For example, lets say you have 25 power, 30 defense, and a weapon that gives you +10 attack and +15 defense, and you do a job that requires X stamina to do, and the payout is between X and X amount of dollars, but the collateral damage is X depending on your stats? You know what I mean?

There is a random funtion in PHP, i think its RAND(0,X) but iam not sure. You can do it in a script, example:
if(($attacker_weapon-$defender_armor)>0)$x=RAND(0,$attacker_weapon-$defender_armor);else $x=-1*(RAND(0,$defender_armor-$attacker_weapon));$damage=$attacker_power+$x-$defender_defence;if($damage<0)$damage=0;
Or so, you just need a healthy imagination =)
As for getting info from database and modifying them, you can learn that from the sites i posted.
If you have any more questions please ask.
Edited by khalilov (see edit history)

Share this post


Link to post
Share on other sites

I really appreciate the reply there. I am going through the sites you posted already, just one at a time, and it's not too hard really. I will continue reading then and if I come across any more issuses I will be sure to ask for the help. Thanks guys. I'm hoping I can have this finished soon.

Share this post


Link to post
Share on other sites

ok the site is already starting to come along, I've got pretty much the non-registered/welcome pages almost done on it, I'm just having a slight issue. I'm trying to keep my vertical nav bar there, but can't seem to figure out how to put it into it's own frame. The nav bar is in CSS, so I'm not too familiar with how to put it into a frame. Do you guys have any suggestions?

Share this post


Link to post
Share on other sites

vertical navigational bar:

p.menu { position:absolute;top:150px;left:40px;height:500px;width:100pxbackground:black;padding-bottom:0px;padding-left:0pxpadding-right:0px;padding-top:0px;color:firebrick;border:1px solid red;text-align: center;}

make a script and name it menu.php
<p class='menu'>INSERT CODES AND LINKS HERE</p>

Then in every page in your site put include('menu.php');
You can customize the menu if you want, by modifying its CSS code you can choose any color you want for the back ground and works. Also to give your menu a simple but cool animation effect add this:
a:link { color: yellow; text-decoration: none; }a:visited { color: yellow; text-decoration: none; } a:hover { color: orange; }

You can modify the color as you want, you can also change the color of the background when you hover over it. I suggest you choose two colors one for words and one for back ground. If you hover your mouse over it, switch them. Example background black, words white. If you hover over then make then worsd black background white. Gives a nice animation.

To me a skilled programer isn't someone who makes complicated programs, its the one who can make attractive effects with simple commands =)
Edited by khalilov (see edit history)

Share this post


Link to post
Share on other sites

ok, well before your post here is what I got and I like the menu created here, and would like to keep it, just can't get it into a frame. My frame isn't working at all. Here is what I have without the frame, then with the frame, and do you see something I'm not seeing?

 

With Frame:

 

<html><body bgcolor="#383838"><head>	  <title>Registration</title></head><frameset cols="140"><frame name="first" noresize="noresize" src="Welcome Nav Bar.html"><frame name="second" noresize="noresize" src="Registration index.html"></frameset><div id="navcontainer"><ul id="navlist"><li id="active"><a href="Registration index.htm" id="current">Registration</a></li><li><a href="Welcome index..htm">Welcome</a></li><li><a href="about.htm">About</a></li><li><a href="#">Login</a></li><li><a href="#">Forum</a></li></ul></div><style type="text/css">		#navcontainer ul		{			margin-left: 30px;			padding: 0;			list-style-type: none;			font-family: Arial, Helvetica, sans-serif;			font-size: 14px;		}				#navcontainer li { margin: 0 0 3px 0; }				#navcontainer a		{			display: block;			padding: 2px 2px 2px 24px;			border: 1px solid #333;			width: 160px;			background-color: #000000;			background-image: url(images/l1_down.gif);		}				#navcontainer a:link, #navlist a:visited		{			color: #990000;			text-decoration: none;		}				#navcontainer a:hover		{			border: 1px solid #333;			background-color: #000066;			background-image: url(images/l1_over.gif);			color: #33FF33;		}				#active a:link, #active a:visited, #active a:hover		{			border: 1px solid #333;			background-color: #CC0000;			background-image: url(images/l1_over.gif);			color: #000000;		}</style><body><p><font color="#FFFFFF"><font align="center"><h1>Terms and Conditions</h1><br><br></p><p> Terms and conditions statement goes here.</p></body></html>
And now without the frame:

 

<html><head><div id="navcontainer"><ul id="navlist"><li id="active"><a href="welcome index.htm" id="current">Welcome</a></li><li><a href="#">About</a></li><li><a href="Registration index..htm">Registration</a></li><li><a href="#">Login</a></li><li><a href="#">Forum</a></li></ul></div><style type="text/css">		#navcontainer ul		{			margin-left: 0px;			padding: 0;			list-style-type: none;			font-family: Arial, Helvetica, sans-serif;			font-size: 14px;		}				#navcontainer li { margin: 0 0 3px 0; }				#navcontainer a		{			display: block;			padding: 2px 2px 2px 24px;			border: 1px solid #333;			width: 120px;			background-color: #999;			background-image: url(images/l1_down.gif);		}				#navcontainer a:link, #navlist a:visited		{			color: #EEE;			text-decoration: none;		}				#navcontainer a:hover		{			border: 1px solid #333;			background-color: #F60;			background-image: url(images/l1_over.gif);			color: #333;		}				#active a:link, #active a:visited, #active a:hover		{			border: 1px solid #333;			background-color: #FF6600;			background-image: url(images/l1_over.gif);			color: #333;		}</style></head></html>
Edited by Leveecius (see edit history)

Share this post


Link to post
Share on other sites

I see you recommend staying away from the frames, and I wouldn't mind trying the idea, what I'm trying to accomplish is to make the site have much easier access for the users. That's why I figured I'd throw in a frame for the nav bar, but I don't know now. lol

Share this post


Link to post
Share on other sites

I see you recommend staying away from the frames, and I wouldn't mind trying the idea, what I'm trying to accomplish is to make the site have much easier access for the users. That's why I figured I'd throw in a frame for the nav bar, but I don't know now. lol

Yes, do not use frames and forget html, your using php, so do it all in php using CSS to arrange the elements. If you take a quick look at an existing codebase you will see that there is little to no html at all.

Share this post


Link to post
Share on other sites

Yes, do not use frames and forget html, your using php, so do it all in php using CSS to arrange the elements. If you take a quick look at an existing codebase you will see that there is little to no html at all.

This is true, but do you think that I need to do the whole game in PHP even though it's just a text based game? That doesn't really seem logical to me. I thought php was more for the flashy type stuff like Java. :rolleyes:

Share this post


Link to post
Share on other sites

This is true, but do you think that I need to do the whole game in PHP even though it's just a text based game? That doesn't really seem logical to me. I thought php was more for the flashy type stuff like Java. :rolleyes:

Yeah do it all in php, html is an overhead thats just ot required. Download and take a look at Legend of the Green Dragon code as an example of how to make a game that will scale from a few users to a few thousand concurrent users.

Share this post


Link to post
Share on other sites

Leveecius, PHP, MYSQL and CSS is all you need to make a great textbased game. I suggest you make it and then if you have any ideas that require Java you can add them. But the entire base of the game should be php.
When you are using php you are using html at the same time

echo "<table><tr>HP</tr><tr>".$hp."</tr></table>";
Assuming that the variable hp was 100, it would show HP and 100 near it.
You could have gotten that with html by simply
<table><tr>HP</tr><tr>100</tr></table>
Both codes print the same result, but by using PHP you can print out any value ($hp), while in html you can only print out the number you put in the code. And since text based games are full of variables (hp,experience,resources...).php is the way to go.
PHP modifies html pages depending on commands on databases.
Edited by khalilov (see edit history)

Share this post


Link to post
Share on other sites

Leveecius, PHP, MYSQL and CSS is all you need to make a great textbased game. I suggest you make it and then if you have any ideas that require Java you can add them. But the entire base of the game should be php. When you are using php you are using html at the same time

echo "<table><tr>HP</tr><tr>".$hp."</tr></table>";
Assuming that the variable hp was 100, it would show HP and 100 near it.
You could have gotten that with html by simply
<table><tr>HP</tr><tr>100</tr></table>
Both codes print the same result, but by using PHP you can print out any value ($hp), while in html you can only print out the number you put in the code. And since text based games are full of variables (hp,experience,resources...).php is the way to go.
PHP modifies html pages depending on commands on databases.

Ok that makes sense. Like I said I'm going to be learning as much as I can about PHP so if I have any questions on any of it I'll be sure to ask you guys! I appreciate your help in all of this! Thanks again everyone. :rolleyes:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.