Jump to content
MakeWebGames

[V2] Help Nedded Please help


Adrian

Recommended Posts

hello i was just woundering if someone could tell me how to change max money in my mccodes version 2 game and put the stats to max aswell they dont have to be max but at leste the stats to like 1bill and the money to like 10quad a

And when i create a gang it says it get created but it dont shouw that is my creatte gang php i added pics doe :)

 

<?php
include "globals.php";
if($ir['money'] < 500000)
{
die("You don't have enough money. You need \$500,000.");
}
if($ir['gang'])
{
die ("You're already in a gang!");
}
if($_POST['submit'])
{
$name=htmlspecialchars($_POST['name']);
$desc=htmlspecialchars($_POST['desc']);
mysql_query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'','')",$c);
$i=$db->insert_id();
$db->query("UPDATE users SET gang=$i,money=money-500000 where userid=$userid");
print "Gang created!";
}
else
{
print "<h3> Create A Gang </h3><form action='creategang.php' method='post'><input type='hidden' name='submit' value='1' />Name:<input type='text' name='name' />
Description:
<textarea name='desc' cols='40' rows='7'></textarea> 
<input type='submit' value='Create Gang for \$500,000' /></form>";
}
$h->endpage();
?>

 

Thanks

Link to comment
Share on other sites

Re: [V2] Help Nedded Please help

 

<?php
include "globals.php";
if($ir['money'] < 500000)
{
die("You don't have enough money. You need \$500,000.");
}
if($ir['gang'])
{
die ("You're already in a gang!");
}
if($_POST['submit'])
{
$name=htmlspecialchars($_POST['name']);
$desc=htmlspecialchars($_POST['desc']);
mysql_query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'')",$c);
$i=$db->insert_id();
$db->query("UPDATE users SET gang=$i,money=money-500000 where userid=$userid");
print "Gang created!";
}
else
{
print "<h3> Create A Gang </h3><form action='creategang.php' method='post'><input type='hidden' name='submit' value='1' />Name:<input type='text' name='name' />
Description:
<textarea name='desc' cols='40' rows='7'></textarea> 
<input type='submit' value='Create Gang for \$500,000' /></form>";
}
$h->endpage();
?>

 

Change to that if you ahve not added any mods to your gangs. When you need help Post Error thats givin...we ahve no idea what ot fix. I do know that you have an extra '' at the end of the query. But I don't know yoru game you might have added mods I dont know....

Link to comment
Share on other sites

Re: [V2] Help Nedded Please help

Go upload the script bellow. And show us the error it's giving you.

 

<?php
include "globals.php";
if($ir['money'] < 500000)
{
die("You don't have enough money. You need \$500,000.");
}
if($ir['gang'])
{
die ("You're already in a gang!");
}
if($_POST['submit'])
{
$name=htmlspecialchars($_POST['name']);
$desc=htmlspecialchars($_POST['desc']);
mysql_query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'')"); or die(mysql_error());
$i=$db->insert_id();
$db->query("UPDATE users SET gang=$i,money=money-500000 where userid=$userid");
print "Gang created!";
}
else
{
print "<h3> Create A Gang </h3><form action='creategang.php' method='post'><input type='hidden' name='submit' value='1' />Name:<input type='text' name='name' />
Description:
<textarea name='desc' cols='40' rows='7'></textarea> 
<input type='submit' value='Create Gang for \$500,000' /></form>";
}
$h->endpage();
?>
Link to comment
Share on other sites

Re: [V2] Help Nedded Please help

Here mate i added the normal Creategang.php and this show up

 

QUERY ERROR: Column count doesn't match value count at row 1
Query was INSERT INTO gangs VALUES('','Test','Test','','',0,0,100,1,1,5,0,0,'')

 

When i added this 1 you gived me this showed up

 

Parse error: syntax error, unexpected T_LOGICAL_OR in /home/worldwar/public_html/creategang.php on line 15

 

Thanks Mates :)

Link to comment
Share on other sites

Re: [V2] Help Nedded Please help

Try this.

 

<?php
include "globals.php";
if($ir['money'] < 500000)
{
die("You don't have enough money. You need \$500,000.");
}
if($ir['gang'])
{
die ("You're already in a gang!");
}
if($_POST['submit'])
{
$name=htmlspecialchars($_POST['name']);
$desc=htmlspecialchars($_POST['desc']);
mysql_query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'','','',)",$c);
$i=$db->insert_id();
$db->query("UPDATE users SET gang=$i,money=money-500000 where userid=$userid");
print "Gang created!";
}
else
{
print "<h3> Create A Gang </h3><form action='creategang.php' method='post'><input type='hidden' name='submit' value='1' />Name:<input type='text' name='name' />
Description:
<textarea name='desc' cols='40' rows='7'></textarea> 
<input type='submit' value='Create Gang for \$500,000' /></form>";
}
$h->endpage();
?>
Link to comment
Share on other sites

Re: [V2] Help Nedded Please help

Mate still aint Working i dont know why i really need help with it :) who helps me gets $5 and when i create item this show up

 

QUERY ERROR: Column count doesn't match value count at row 1
Query was INSERT INTO items VALUES('',4,'BodyGuard','BodyGuard Protects Your From Attacking',0,0,0, '1', 'a:4:{s:4:\"stat\";s:9:\"protected\";s:3:\"dir\";s:3:\"pos\";s:8:\"inc_type\";s:6:\"figure\";s:10:\"inc_amount\";i:24;}', '0', 'a:4:{s:4:\"stat\";s:6:\"energy\";s:3:\"dir\";s:3:\"pos\";s:8:\"inc_type\";s:6:\"figure\";s:10:\"inc_amount\";i:0;}', '0', 'a:4:{s:4:\"stat\";s:6:\"energy\";s:3:\"dir\";s:3:\"pos\";s:8:\"inc_type\";s:6:\"figure\";s:10:\"inc_amount\";i:0;}', 0, 0, 0, 0, 0, 0, 0, 0)

 

and i did fill all the spaces in Help $5 Is Wating :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...