LavaSCRIPT L9 Tamagochi, smile generator

Started on the old forum in November 2009 · view the original in the archive · old links redirect here

65 replies · 9,023 views · started 17 years ago · 6 min read

TL;DR · summary of 65 replies
  • kabooms forgot to upload ip_files/ folder which caused warnings and errors.
  • wapmaster2 encountered issues with IP address country detection and needed help locating the missing files.
  • The error was resolved by creating a flag file named "unknown.png" or "unknown.gif" in the flag folder, as suggested by kabooms.
  • kei_ki7 faced an issue with the cleardata() function not being properly closed, which was fixed by adding a closing brace at line 5 of their code.

Written automatically from the replies by a language model on our own server. It can be wrong; the posts below are the source.

26 participants
kei_ki7 Senior · 431 posts #41
$unick3 = getnick_uid($attack3);
$msg = "You won $noen plusses. Consolation prize in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $attack3);
$res = mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='WAP Jueteng winning number combinations are $attack and $attack1. Consolation Prize goes to $unick3, You will received $noen plusses. congratulations -yay-', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noen' WHERE id='".$attack3."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value=' ', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
} //line 1
   } //line 2
 } //line 3
} //line 4

i got error from line 4, and i saw in the function of cleardata() is not close so i add "}" to line 5

} //line 1
   } //line 2
 } //line 3
} //line 4
} //line 5

then the errors is in line 5

Did I help you? You can help me too Your donations will help me finance my studies.

kabooms Developer · 80 posts #42

kei_ki7 this too easy. code already posted and make some effort on it basic php tags

 function()
{ //start
} //end

function cleardata()
{
My code that i posted

NEXT THE REST OF YOUR CODE UNDER CLEARDATA() FUNCTION AND CLOSE it ..

}
kabooms Developer · 80 posts #43

try to update yours

/////////////////jueteng draw
function drawnow()
{
   $nopop = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
   return $nopop[0];
}

function win($attack, $attack1)
{
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng WHERE no1 LIKE '%".$attack."%' AND no2 LIKE '%".$attack1."%'"));
   return $noi[0];
}
///end jueteng draw

///////////////////clear data

function cleardata()
{

         ////jueteng
$now = time();
$start=date("Y-m-d")." 07:00:00";
$end=date("Y-m-d")." 07:00:10";
$tstamp1=strtotime($start);
$tstamp2=strtotime($end);
if($now>$tstamp1 && $now<$tstamp2)
{
    if(drawnow())
 {
    $rand = mysql_query("SELECT no1 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack1 =$rands[0];
    }
    $rand = mysql_query("SELECT no2 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack =$rands[0];
    }
    if(win($attack, $attack1))
    {
$ilan = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noil = $ilan[0]*90;
$noi2 = $noil*0.10;
$noi = mysql_fetch_array(mysql_query("SELECT uid FROM ph_bazzztord_jueteng WHERE no1 LIKE '%".$attack."%' AND no2 LIKE '%".$attack1."%'"));
$res = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res)
{
$noi2plus = $noi2+500;
$unick4 = getnick_uid($noi[0]);
$msg = "You won $noi2plus plusses in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $noi[0]);
mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='Congratulations! $unick4 your wap jueteng numbers matched to our winning numbers $attack and $attack1. $noi2plus plusses has been added!', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noi2plus' WHERE id='".$noi[0]."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value='".$noi[0]."', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }else{
    $random = mysql_query("SELECT uid FROM ph_bazzztord_jueteng ORDER by RAND() LIMIT 1");
    while($randsom=mysql_fetch_array($random))
    {
    $attack3 =$randsom[0];
    }
$non = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noin = $non[0]*60;
$noen = $noin*0.40;
$res2 = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res2)
{
$unick3 = getnick_uid($attack3);
$msg = "You won $noen plusses. Consolation prize in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $attack3);
$res = mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='WAP Jueteng winning number combinations are $attack and $attack1. Consolation Prize goes to $unick3, You will received $noen plusses. congratulations -yay-', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noen' WHERE id='".$attack3."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value=' ', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }
 }
}

  $nw = time(); 
  $strt=date("Y-m-d")." 12:00:00";
  $nd=date("Y-m-d")." 12:00:10";
  $stamp1=strtotime($strt);
  $stamp2=strtotime($nd);
  if($nw>$stamp1 && $nw<$stamp2) 
  {
if(drawnow())
 {
    $rand = mysql_query("SELECT no1 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack1 =$rands[0];
    }
    $rand = mysql_query("SELECT no2 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack =$rands[0];
    }
    if(win($attack, $attack1))
    {
$ilan = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noil = $ilan[0]*90;
$noi2 = $noil*0.10;
$noi = mysql_fetch_array(mysql_query("SELECT uid FROM ph_bazzztord_jueteng WHERE no1 LIKE '%".$attack."%' AND no2 LIKE '%".$attack1."%'"));
$res = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res)
{
$noi2plus = $noi2+500;
$unick4 = getnick_uid($noi[0]);
$msg = "You won $noi2plus plusses in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $noi[0]);
mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='Congratulations! $unick4 your wap jueteng numbers matched in our winning numbers $attack and $attack1. $noi2plus plusses has been added!', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noi2plus' WHERE id='".$noi[0]."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value='".$noi[0]."', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }else{
    $random = mysql_query("SELECT uid FROM ph_bazzztord_jueteng ORDER by RAND() LIMIT 1");
    while($randsom=mysql_fetch_array($random))
    {
    $attack3 =$randsom[0];
    }
$non = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noin = $non[0]*60;
$noen = $noin*0.40;
$res2 = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res2)
{
$unick3 = getnick_uid($attack3);
$msg = "You won $noen plusses. Consolation prize in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $attack3);
$res = mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='WAP Jueteng winning number combinations are $attack and $attack1. Consolation Prize goes to $unick3, You will received $noen plusses. congratulations -yay-', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noen' WHERE id='".$attack3."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value=' ', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }
 }
}

  $nw = time(); 
  $strt=date("Y-m-d")." 19:00:00";
  $nd=date("Y-m-d")." 19:00:10";
  $stamp1=strtotime($strt);
  $stamp2=strtotime($nd);
  if($nw>$stamp1 && $nw<$stamp2) 
  {
if(drawnow())
 {
    $rand = mysql_query("SELECT no1 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack1 =$rands[0];
    }
    $rand = mysql_query("SELECT no2 FROM ph_bazzztord_juetengnum ORDER by RAND() LIMIT 1");
    while($rands=mysql_fetch_array($rand))
    {
    $attack =$rands[0];
    }
    if(win($attack, $attack1))
    {
$ilan = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noil = $ilan[0]*90;
$noi2 = $noil*0.10;
$noi = mysql_fetch_array(mysql_query("SELECT uid FROM ph_bazzztord_jueteng WHERE no1 LIKE '%".$attack."%' AND no2 LIKE '%".$attack1."%'"));
$res = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res)
{
$noi2plus = $noi2+500;
$unick4 = getnick_uid($noi[0]);
$msg = "You won $noi2plus plusses in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $noi[0]);
mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='Congratulations! $unick4 your wap jueteng numbers matched to our winning numbers $attack and $attack1. $noi2plus plusses has been added!', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noi2plus' WHERE id='".$noi[0]."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value='".$noi[0]."', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }else{
    $random = mysql_query("SELECT uid FROM ph_bazzztord_jueteng ORDER by RAND() LIMIT 1");
    while($randsom=mysql_fetch_array($random))
    {
    $attack3 =$randsom[0];
    }
$non = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_jueteng"));
$noin = $non[0]*60;
$noen = $noin*0.40;
$res2 = mysql_query("DELETE FROM ph_bazzztord_jueteng");
if($res2)
{
$unick3 = getnick_uid($attack3);
$msg = "You won $noen plusses. Consolation prize in wap jueteng draw!"."[br/][small]Note: This is an automatic PM[/small]";
autopm($msg, $attack3);
$res = mysql_query("INSERT INTO ph_bazzztord_shouts SET shout='WAP Jueteng winning number combinations are $attack and $attack1. Consolation Prize goes to $unick3, You will received $noen plusses. congratulations -yay-', shouter='332', shtime='".time()."'");
mysql_query("UPDATE ph_bazzztord_users SET plusses=plusses+'$noen' WHERE id='".$attack3."'");
mysql_query("UPDATE ph_bazzztord_juetengset SET value=' ', no1='".$attack."', no2='".$attack1."', time='".time()."' WHERE name='lottonum'");
}
   }
 }
}    

$timeto = 500;
  $timenw = time();
  $timeout = $timenw - $timeto;
  $timeto = 120;
  $timenw = time();
  $timeout = $timenw - $timeto;
  $exec = mysql_query("DELETE FROM ph_bazzztord_chonline WHERE lton<'".$timeout."'");
  $timeto = 300;
  $timenw = time();
  $timeout = $timenw - $timeto;
  $exec = mysql_query("DELETE FROM ph_bazzztord_chat WHERE timesent<'".$timeout."'");
  $timeto = 60*60;
  $timenw = time();
  $timeout = $timenw - $timeto;
  $exec = mysql_query("DELETE FROM ph_bazzztord_search WHERE stime<'".$timeout."'");
  

  ///delete expired rooms
  $start2 = mktime(0, 0); // midnight today
  $gettime = mysql_fetch_array(mysql_query("SELECT MAX(value) FROM ph_bazzztord_settings WHERE name='reset'"));
  $timenw = time() + (14 * 3600);
 $timeto = mktime(0, 0); // midnight today
  $timeto -= 24*60*60;
    $start = $gettime[0]+57600;
  $timeto = 5*60;
  $timenw = time();
  $timeout = $timenw - $timeto;
  $rooms = mysql_query("SELECT id FROM ph_bazzztord_rooms WHERE static='0' AND lastmsg<'".$timeout."'");
  while ($room=mysql_fetch_array($rooms))
  {
    $ppl = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_chonline WHERE rid='".$room[0]."'"));
    if($ppl[0]==0)
    {
        $exec = mysql_query("DELETE FROM ph_bazzztord_rooms WHERE id='".$room[0]."'");
    }
  }
  $lbpm = mysql_fetch_array(mysql_query("SELECT value FROM ph_bazzztord_settings WHERE name='lastbpm'"));
  $td = date("Y-m-d");
  //echo $lbpm[0];

  $tm = time();
  $antiflood = 86400;
  $lastpm = mysql_fetch_array(mysql_query("SELECT MAX(value) FROM ph_bazzztord_settings WHERE name='resetsht'"));
  $pmfl = $lastpm[0]+$antiflood;
  if($pmfl<$tm)
  {
  $time_to = 7*24*60*60;
  $timenw = time();
  $inactive_time = $timenw - $timeto;
  $sql2 = "SELECT id FROM ph_bazzztord_users WHERE lastact<'".$inactive_time."'";
        $ppl2 = mysql_query($sql2);
        while($mem2 = mysql_fetch_array($ppl2))
        {
$blg = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ph_bazzztord_tamagotchi WHERE uid='".$who."'"));
if($blg[0])
{
  $res3 = mysql_query("DELETE FROM ph_bazzztord_tamagotchi WHERE uid='".$mem2[0]."'");
  if($res3)
  {
$text = "Your Tamagotchi died because you are Inactive for 7 days. :( [b]Note: This is an automatic pm[/b]";
mysql_query("INSERT INTO ph_bazzztord_private SET text='".$text."', byuid='334', touid='".$mem2[0]."', timesent='".time()."'");
  }
}
        }
      
        $sql3 = "SELECT id, uid FROM ph_bazzztord_tamagotchi WHERE feed<=0";
        $ppl3 = mysql_query($sql3);
        while($mem3 = mysql_fetch_array($ppl3))
        {
  $res1 = mysql_query("DELETE FROM ph_bazzztord_tamagotchi WHERE id='".$mem3[0]."'");
  if($res1)
  {
$text = "Your Tamagotchi died because of hunger. :( [b]Note: This is an automatic pm[/b]";
mysql_query("INSERT INTO ph_bazzztord_private SET text='".$text."', byuid='334', touid='".$mem3[1]."', timesent='".time()."'");
  }
        }      
  }      
  
  if ($td!=$lbpm[0])
  {
   //echo "boo";
   $sql = "SELECT id, name, birthday  FROM ph_bazzztord_users where month(`birthday`) = month(curdate()) and dayofmonth(`birthday`) = dayofmonth(curdate())";
   $ppl = mysql_query($sql);
   while($mem = mysql_fetch_array($ppl))
   {
      $msg = "[card=008]to you $mem[1]"."[/card] $sitename team wish you a day full of joy and happiness and many happy returns[br/]*fireworks*[br/][small][i]p.s: this is an automated pm[/i][/small]";
      autopm($msg, $mem[0]);
   }

   $sql2 = "SELECT id FROM ph_bazzztord_tamagotchi";
   $ppl2 = mysql_query($sql2);
   while($mem2 = mysql_fetch_array($ppl2))
   {
   mysql_query("UPDATE ph_bazzztord_tamagotchi SET feed=feed-1, play=play-1, learn=learn-1, health=health-1, clean=clean-1, vanna=vanna-1 WHERE id='".$mem2[0]."'");
   }

   mysql_query("UPDATE ph_bazzztord_settings SET value='".$td."' WHERE name='lastbpm'");
  }
  
}

///////////////////////////////////////

😑

arg0s12 Developer · 144 posts #44

This scripts working at my site, from lucky9 to Jueteng, , maybe theres some error but i'll try to learn and understand, thanks bro, nwei, will you post the code in profile bout online stat?

arg0s12 Developer · 144 posts #45

i use ur online function. .

kabooms Developer · 80 posts #46

what online stat in profile bro?

kei_ki7 Senior · 431 posts #47

thanks kaboom, i do not first use the core then i let the errors show so i see the errors by the way thanks

Did I help you? You can help me too Your donations will help me finance my studies.

KiLLeR_mAcHInE Developer · 128 posts #49

kabooms wrote: welcome joseg tnt

heres Smile Generator for lava wml and xhtml

thanks bro

:-):-):-):-) any probs PM me ??? :-):-):-):-):-) c yA

Richie24 Developer · 193 posts #50

your sql for the tam game is fooked

Error SQL query:

-- -- Dumping data for table ph_bazzztord_faqs -- INSERT INTO ph_bazzztord_faqs (id, category, question, answer) VALUES (2, '', 'What are those stats?', 'If one of parameters will exceed 150% or becomes below 0% the kapet will die.'), (3, '', 'How to feed my KAPet?', 'Just tell your friends to feed your pet and 300 plusses will be deducted from their account per feed.'), (4, '', 'No Feeding Limitation?', 'KAPet can only be feed once a day.'), (5, '', 'How to challenge other masters?', 'You can make a challenge if you reached level 10.'), (6, '', 'How does my pet level up?', 'Other members need to feed your pet by clicking the link Feed My Pet!'), (7, '', 'What are levels for?', 'Levels are just a fun thing for our kapet. If your pet gets a high enough level it will be placed in the top.'), (8, '', 'How to Challenge?', 'Ur level should be 10 as well as ur opponent. View the profile of the pet then click send challenge. Place your bet and send the challenge. u[...]

MySQL said:

#1062 - Duplicate entry '2' for key 1

arg0s12 Developer · 144 posts #51

Richie24 wrote: your sql for the tam game is fooked

Error SQL query:

-- -- Dumping data for table ph_bazzztord_faqs -- INSERT INTO ph_bazzztord_faqs (id, category, question, answer) VALUES (2, '', 'What are those stats?', 'If one of parameters will exceed 150% or becomes below 0% the kapet will die.'), (3, '', 'How to feed my KAPet?', 'Just tell your friends to feed your pet and 300 plusses will be deducted from their account per feed.'), (4, '', 'No Feeding Limitation?', 'KAPet can only be feed once a day.'), (5, '', 'How to challenge other masters?', 'You can make a challenge if you reached level 10.'), (6, '', 'How does my pet level up?', 'Other members need to feed your pet by clicking the link Feed My Pet!'), (7, '', 'What are levels for?', 'Levels are just a fun thing for our kapet. If your pet gets a high enough level it will be placed in the top.'), (8, '', 'How to Challenge?', 'Ur level should be 10 as well as ur opponent. View the profile of the pet then click send challenge. Place your bet and send the challenge. u[...]

MySQL said:

#1062 - Duplicate entry '2' for key 1

because you try to run your sql twice..and once just change the ph_bazzztord_faqs to pet_faqs and if tour post appear delete first your table then run again..

huwad Developer · 215 posts #52

Richie24 wrote: your sql for the tam game is fooked

Error SQL query:

-- -- Dumping data for table ph_bazzztord_faqs -- INSERT INTO ph_bazzztord_faqs (id, category, question, answer) VALUES (2, '', 'What are those stats?', 'If one of parameters will exceed 150% or becomes below 0% the kapet will die.'), (3, '', 'How to feed my KAPet?', 'Just tell your friends to feed your pet and 300 plusses will be deducted from their account per feed.'), (4, '', 'No Feeding Limitation?', 'KAPet can only be feed once a day.'), (5, '', 'How to challenge other masters?', 'You can make a challenge if you reached level 10.'), (6, '', 'How does my pet level up?', 'Other members need to feed your pet by clicking the link Feed My Pet!'), (7, '', 'What are levels for?', 'Levels are just a fun thing for our kapet. If your pet gets a high enough level it will be placed in the top.'), (8, '', 'How to Challenge?', 'Ur level should be 10 as well as ur opponent. View the profile of the pet then click send challenge. Place your bet and send the challenge. u[...]

MySQL said:

#1062 - Duplicate entry '2' for key 1

change the value of 2 for the key 1 or delete the 1 row that made some conflict

or simply post the table and its dumping data here,, ill do it for you..

hacking is like sex. you get in, you get out and you pray you left nothing behind.

dj_toon Newbie · 6 posts #53

oooo this gives me something to do thanx mate have been looking for some of theses codes nice one

Insane-hosting in the house

icen01 Developer · 72 posts #56

can you also share us the sql of that gsm.pinoy3g.info script thankz lol... i have a little question, is that script complete thanks tnt........

pin0y likes wap

Wapito Newbie · 8 posts #57

Tol ok ah..pti conversation ncopy p..db script ng crazy chat 2?..

robzky Developer · 205 posts #59

Fatal error: Call to undefined function pending() in /home/kozmoz/public_html/chat.php on line 811

what is the code of this function? thanks

LESS TALK. LESS MISTAKE.

HTTP://APPSROB.COM - LIST OF MY FACEBOOK APPS!

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close