
chaoswar4u
Banned-
Posts
221 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Everything posted by chaoswar4u
-
Is there any better system on the voting for sites on MC code V2 to stop scamming. E.G using multi accounts to do X amount of voting. ANy ideas what people have used would be great.
-
Im in need of adding an attack limit onto the attacks. I currently use a one click attack system that I require to end at say 50 steps in the attack if the fight is not won. Like a stalemate where both members walk. Can anyone help on how to do such a task. Many thx in advance.
-
Im in need of something to remove everything from the markets and send it back the the adders like every week. The reason is to reset the market and remove all the highly priced goods that will never sell and just make the list bigger. I require a removal system for such as the items market and one for the crystals. Any help on this would be great. Thx in advance.
-
Re: Mc Code V2 Problems. Help required. Here is another. Any info to make any of my fixes better are welcom. Find in forums.php under function newtopic() Find in that function $u=$ir['username']; if($ir['ul_color']) { $uname="<font color='{$ir['ul_color']}'>"; if($ir['ul_isbold']) { $uname.=""; } $uname.=$ir['username']; if($ir['ul_isbold']) { $uname.=""; } $uname.="</font>"; $u=$uname; } else if($ir['donatordays']) { $u = "<font color=red>{$ir['username']}</font>"; } add under if($_POST['ft_name'] == "") { print "You did not enter a topic name. "; $h->endpage(); exit; } This will stop users placing no names in the topics on forums that result in no access and which makes the post only removable by database.
-
Re: Mc Code V2 Problems. Help required. For anyone who wants it. This is one step I made to fixing the problem. In preferences find function do_name_change() { global $db,$ir,$c,$userid,$h; if($_POST['newname'] == "") { print "You did not enter a new name. > Back"; } else { $_POST['newname']=str_replace(array("<", ">", "\\\'"), array("<", ">", "'"), $_POST['newname']); $db->query("UPDATE users SET username='{$_POST['newname']}' WHERE userid=$userid"); print "Username changed!"; } } and replace with function do_name_change() { global $db,$ir,$c,$userid,$h; if($_POST['newname'] == "") { print "You did not enter a new name. > Back"; } else { if (eregi("( )", $_POST['newname'])) { print"Spaces aren't allowed."; $h->endpage(); exit; } else { $_POST['newname']=str_replace(array("<", ">", "\\\'"), array("<", ">", "'"), $_POST['newname']); $db->query("UPDATE users SET username='{$_POST['newname']}' WHERE userid=$userid"); print "Username changed!"; } } }
-
Re: Small Problem. Duh figured it out. item_add($winner,$item,1); Thx for the replies anyways.
-
Re: Small Problem. mysql_query("insert into inventory VALUES('',$item,$winner,1)",$c) or die(mysql_error()) is a line of code from v1 Isomerizer . I run v2 so i require that line to be a item_add so it autoquintifies the items back into users inventory.
-
I require this to be an item add line. mysql_query("insert into inventory VALUES('',$item,$winner,1)",$c) or die(mysql_error()) I currently have this - item_add($item,$winner,1); It dosent cause an error with my attempt but it dosent credit to the users inventory either. Can some please help point out my error. Many thx in advance.
-
Re: V2 inventory problem Yes but has he edited the one hes running now thats why I said has he used the original to rule out coding error. V2 has standard dosent have this bug.
-
Re: V2 inventory problem It isnt a main code bug. Coding error has made that one appear. Have you tried replaing the inventory.php with the original that you purchased.
-
I have a 3problems. 1 is users when posting on the forums. If they post something with a blank topic it becomes no access to all and it carnt be deleted by staff via the links. DB Only. My next problem is some members are thinking its great to start renaming there account with spaces thus resulting in a blank name. Making them invisable almost as they carnt be linked too. This also can be done for gang names also which is the 3rd problem. Anything that I could use to stop this would be great. Please help. Thx for any elp in advance my friends of CE.
-
Getting Rid of the 2.147 bil cap in MCcode
chaoswar4u replied to Arson's topic in General Discussion
Re: Getting Rid of the 2.147 bil cap in MCcode Bigint will let you calculate upto 9.2 Quint. Example 9.200,000,000,000,000,000 Mind you if your game is at that economy then your in trouble. -
Re: Job edit bug in MCcode V2 help! Already tried that. It comes up with this error if you do that. QUERY ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
-
In staff panel if you use the edit job rank link you will enter for the information. When you submit the changes you get this error. QUERY ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'jrID=' at line 1 Query was UPDATE jobranks SET jrNAME='Captain', jrJOB = 3, jrPAY= 2000, jrIQG=26, jrLABOURG=26, jrSTRG=26, jrIQN=16225, jrLABOURN=16225, jrSTRN=16225WHERE jrID= The code around this is function jobrankedit() { global $db,$ir,$userid; if ( $_POST['stage2']) { $db->query("UPDATE jobranks SET jrNAME='{$_POST['jrNAME']}', jrJOB = {$_POST['jrJOB']}, jrPAY= {$_POST['jrPAY']}, jrIQG={$_POST['jrIQG']}, jrLABOURG={$_POST['jrLABOURG']}, jrSTRG={$_POST['jrSTRG']}, jrIQN={$_POST['jrIQN']}, jrLABOURN={$_POST['jrLABOURN']}, jrSTRN={$_POST['jrSTRN']}WHERE jrID={$_POST['jrID']}"); print "Job rank updated! "; } Any help would be great. Thx
-
Re: [V1] FREE! ID refiller/counter Id Refiller Counter V2 CREATE TABLE free_ids ( id INT( 11 ) NOT NULL ) TYPE=MYISAM ; Add to cron_day $q=$db->query("SELECT userid FROM users ORDER BY userid DESC"); $total=$db->num_rows($q); while($total > 0) { $q2=$db->query("SELECT * FROM users WHERE userid={$total}"); $q3=$db->query("SELECT * FROM free_ids WHERE id={$total}"); if($db->num_rows($q2) == 0 and $db->num_rows($q3) == 0) { $db->query("INSERT INTO free_ids (id) VALUES ({$total});"); } $total--; } In register.php Find $db->query("INSERT INTO users (username, login_name, userpass, level, money, crystals, donatordays, user_level, energy, maxenergy, will, maxwill, brave, maxbrave, hp, maxhp, location, gender, signedup, email, bankmoney, lastip) VALUES( '{$username}', '{$_POST['username']}', md5('{$_POST['password']}'), 1, $sm, 1, 0, 1, 12, 12, 100, 100, 5, 5, 100, 100, 1, 'Male', unix_timestamp(), '{$_POST['email']}', -1, '$ip');") $i=mysql_insert_id($c); Replace $getidq=$db->query("SELECT * FROM free_ids ORDER BY id DESC LIMIT 1;"); if($db->num_rows($getidq) == 0) { $id=""; } else { $getid=$db->fetch_row($getidq); $id=$getid['id']; } if($db->num_rows($getidq)) { $db->query("DELETE FROM free_ids WHERE id={$id}"); } $db->query("INSERT INTO users (userid, username, login_name, userpass, level, money, crystals, donatordays, user_level, energy, maxenergy, will, maxwill, brave, maxbrave, hp, maxhp, location, gender, signedup, email, bankmoney, lastip, lastip_signup) VALUES('$id' ,'{$username}', '{$_POST['username']}', md5('{$_POST['password']}'), 1, $sm, 1, 0, 1, 12, 12, 100, 100, 5, 5, 100, 100, 1, '{$_POST['gender']}', unix_timestamp(), '{$_POST['email']}', -1, '$IP', '$IP')"); $i=mysql_insert_id($c); This is my V2 of this mod from OXI. Works perfect. +1 for you oxi
-
Re: Gang OCs v2 Edit OC via database for V2. Ensure you fix the cron that has the hrs countdown for OC or you will find that crimes start to go into negative time left.
-
Re: [V1] FREE! ID refiller/counter Come on OXI dont ditch this bro. This would be great for all users. :mrgreen:
-
Re: User ID Number Re Order ! Found the post UCC Thx.
-
Re: User ID Number Re Order ! Thx for the reply Decepti0n but where would this go? I assume it would be register.php but where. This is just way out for me at the moment.
-
I wish to make it that when new users register they will be given the ID number next in order. What I mean by this is that when you have had a game running for a while and you decide to remove inactive accounts you will be left with gaps all over regarding the ID order. To combat this I require the register.php to search for such gaps and replace them when new users register. Ive had input from a user already but such a task like this I havent a clue where to start. I really be greatful if anyone can help with this matter. Thx
-
Hi all. I have a few problems in V2 yet to resolve. The problems are listed below. 1) Gangs have the ability to rename there gang to "Blank" nothing so peeps cannot declare war or even click on there gang for details. 2) In the forums people sometimes people forget to place a topic name thus it will there again show a blank box and thus not allowing it to be accessed. Alittle code input to help resolve this would be great.
-
Re: View User Lag? Thx. Added a primary key and its seems to have improved it lots. Thx UCC.
-
Well ive seen this happen on a few V2 games. Everything seems to be fine but when selecting to view a users profile 75% of them will be delayed about 5 - 10 secs before displaying the profile. Is there anyway that this could be speed up?
-
Re: [mccode] Multiple Event Deleter After this mass replies in this topic and people posting fixes for someone to say that code is missing etc is anyone out there willing to post the complete fixed version of this for everyone. Would help alot for everyone. Thx
-
Re: Forums Problem. Ye would help if i told people that. Forums MCCode V2