Login
Username: Password:
Remember me

[Sign Up] / [Recover Password]

Theme / Language

Popular
New Torrents
new name
Size: 18.40 MB
Most active
new name
S: 74 L: 3
New Posters
Snatchlist
Controls ·  Search New posts · Mark unread

You are in: Forum / Forum / v2.08 / v2.08 Mods Completed

Unknown User
2015-03-26 12:27:12
[size=14px]This is the original mod created by mostvotedplaya, improved by ArcticWolf and easy modified by me.
I added again this mod because now unfortunately is missing.
[/size]


Add to your database:

CREATE TABLE IF NOT EXISTS `snatched` (
  `sid` int(11) unsigned NOT NULL auto_increment,
  `tid` int(11) unsigned NOT NULL default '0',
  `uid` int(11) unsigned NOT NULL default '0',
  `stime` int(11) unsigned NOT NULL default '0',
  `utime` int(11) unsigned NOT NULL default '0',
  `ltime` int(11) unsigned NOT NULL default '0',
  `uload` bigint(20) unsigned NOT NULL default '0',
  `dload` bigint(20) unsigned NOT NULL default '0',
  `completed` enum('0','1') NOT NULL default '0',
  `hnr` enum('no','yes') NOT NULL default 'no',
  PRIMARY KEY  (`sid`),
  UNIQUE KEY `tid_uid` (`tid`,`uid`),
  KEY `completed` (`completed`),
  KEY `tid` (`tid`),
  KEY `uid` (`uid`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

Open backend/functions.php

After:
SQL_Query_exec("DELETE FROM reports WHERE votedfor = $id AND type = 'torrent'");

Add:
SQL_Query_exec("DELETE FROM `snatched` WHERE `tid` = '$id'");

After:
SQL_Query_exec("DELETE FROM pollanswers WHERE userid = $userid");

Add:
SQL_Query_exec("DELETE FROM `snatched` WHERE `uid` = '$userid'");

In the most bottom place, before ?> add:
function seedtime($ts = 0)
{                                                                                                    
    $days = floor($ts / 86400);
    $hours = floor($ts / 3600 ) % 24;    
    $mins = floor($ts / 60) % 60;
    $secs = $ts % 60;
    return sprintf( '%d days, %d hours, %d minutes, %d seconds...', $days, $hours, $mins, $secs);
}

Open announce.php

Find:
$ret = SQL_Query_exec("INSERT INTO peers (connectable, torrent, peer_id, ip, passkey, port, uploaded, downloaded, to_go, started, last_action, seeder, userid, client) VALUES ('$connectable', $torrentid, " . sqlesc($peer_id) . ", " . sqlesc($ip) . ", " . sqlesc($passkey) . ", $port, $uploaded, $downloaded, $left, '".get_date_time()."', '".get_date_time()."', '$seeder', '$userid', " . sqlesc($agent) . ")");

Underneath add:
if ( ($MEMBERSONLY) && (($seeder == 'no' && $torrent['freeleech'] == 0)) ) {
    SQL_Query_exec("INSERT INTO `snatched` (`uid`, `tid`, `stime`, `utime`) VALUES ('$userid', '$torrentid', '".gmtime()."', '".gmtime()."') ON DUPLICATE KEY UPDATE `utime` = '" . gmtime() . "'");
}

Find:
if ( $MEMBERSONLY )
SQL_Query_exec("INSERT INTO completed (userid, torrentid, date) VALUES ($userid, $torrentid, '".get_date_time()."')");

Replace with:
if ( $MEMBERSONLY )
{
    SQL_Query_exec("INSERT INTO completed (userid, torrentid, date) VALUES ($userid, $torrentid, '".get_date_time()."')");
    SQL_Query_exec("UPDATE LOW_PRIORITY `snatched` SET `completed` = '1' WHERE `tid` = '$torrentid' AND `uid` = '$userid' AND `utime` = '" . gmtime() . "'");
}

Find:
$upthis = max(0, $uploaded - $self["uploaded"]);

Above add:
$elapsed = ($self['seeder'] == 'yes') ? $site_config['announce_interval'] - floor(($self['ez'] - time()) / 60) : 0;

Find:
if (($upthis > 0 || $downthis > 0) && is_valid_id($userid))

Replace with:
if (($upthis > 0 || $downthis > 0 || $elapsed > 0) && is_valid_id($userid))

Find:
SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis, downloaded = downloaded + $downthis WHERE id=$userid") or err("Tracker error: Unable to update stats");

Underneath add:
SQL_Query_exec("UPDATE LOW_PRIORITY `snatched` SET `uload` = `uload` + '$upthis', `dload` = `dload` + '$downthis', `utime` = '".gmtime()."', `ltime` = `ltime` + '$elapsed' WHERE `tid` = '$torrentid' AND `uid` = '$userid'");

Open account.php

Under:
<?php print("<a href='mailbox.php'><b>".T_("YOUR_MESSAGES")."</b></a>");?>

Add:
&nbsp;|&nbsp;
<?php print("<a href='snatched.php'><b>".T_("YOUR_SNATCHLIST")."</b></a>");?>

Open account-details.php

Before:
<?php echo T_("AGE"); ?>: <?php echo htmlspecialchars($user["age"])?><br />

Add:
<?php if ($CURUSER["edit_users"]=="yes" && $CURUSER["class"] > $user["class"]) { ?>
  <div style="margin-bottom:3px"><a href="snatched.php?uid=<?php echo $user["id"]?>"><?php echo "<input type='submit' value='".T_("SNATCHLIST")."'>"; ?></a></div>
<?php } ?>

Open torrents-details.php

Under:
echo "[<a href='torrents-edit.php?id=$row[id]&amp;returnto=" . urlencode($_SERVER["REQUEST_URI"]) . "'><b>".T_("EDIT_TORRENT")."</b></a>]";

Add:
echo "&nbsp;<a href=snatched.php?tid=$row[id]><input type='submit' value='".T_("SNATCHLIST")."'></a>&nbsp;";

Open languages/english.php

Add:
//===| Snatchlist
$LANG["SNATCHLIST"] = "Snatchlist";
$LANG["YOUR_SNATCHLIST"] = "Your Snatchlist";
$LANG["SNATCHLIST_FOR"] = "Snatchlist For:";
$LANG["LAST_ACTION"] = "Last Action";
$LANG["SEED_TIME"] = "Seed Time";
$LANG["GO_TO_YOUR_PROFILE"] = "Go to Your Profile";
$LANG["GO_TO_USER_ACCOUNT"] = "Go to User Account";
$LANG["HNR"] = "<font color=#FF1200><b>H</b><small>&</small><b>R</b></font>";
$LANG["SNATCHED_MESSAGE"] = "This page displays the details to all downloaded torrents, completed or not.";
$LANG["NO_USER_WITH_ID"] = "There is no user with ID: ";
$LANG["NO_TORRENT_WITH_ID"] = "There is no torrent with ID: ";
$LANG["REGISTERED_MEMBERS_TO_TORRENT"] = "Registered Members To Torrent:";
$LANG["NO_PERMISSION"] = "You don't have permission for this action!";
$LANG["T_L_OR_E"] = "Local or External";
$LANG["LOCAL_TORRENT"] = "Local Torrent";
$LANG["EXTERNAL_TORRENT"] = "External Torrent";
$LANG["FREE"] = "Free";

[size=14px]Finally, extracts the atached archive "snatched.zip" and upload the images and snatched.php into your root.[/size]
[url="http://devscorner.xyz/applications/core/interface/file/attachment.php?id=7186"]snatched.zip[/url]
snatched.zip
Download
Unknown User
2015-03-26 14:56:31
thanks you BigMax
2015-04-04 20:09:42
[size=14px][color=rgb(255,215,0)]Thanks You BigMax[/color][/size]  :D
Unknown User
2015-04-05 14:36:21
hi, It's a add-on for this mod=> [url="http://devscorner.xyz/topic/17641-anti-hit-run-system/"]http://devscorner.xyz/topic/17641-anti-hit-run-system/[/url]or it's replace hit&run?

thx
2015-04-05 15:59:58
You need this mode to install this [url="http://devscorner.xyz/topic/17641-anti-hit-run-system/"]http://devscorner.xyz/topic/17641-anti-hit-run-system/[/url]
Unknown User
2015-04-05 16:02:37
This mod is ready for "Anti Hit & Run System", so Snatchlist must be installed first.
Unknown User
2015-04-05 16:22:50
thank you guys! so first I install this hack and next it's anti&run, thx
Unknown User
2015-04-05 17:59:39
I don't understand, I have to make changes in announce.php and installing the hack hit & run, I have to remove what the hack snatchlist told me to put
2015-04-05 18:35:56
"mitch84, post: 93839":

I don't understand, I have to make changes in announce.php and installing the hack hit & run, I have to remove what the hack snatchlist told me to put
not you install all!  ;)
Unknown User
2015-04-05 18:58:18
I do not know now what I need to change in the file annouce  :blink:
2015-04-05 23:53:15
"mitch84, post: 93842":

I do not know now what I need to change in the file annouce  :blink:  
if you installed the mod H & R you have nothing to change

snatchlist here, add SQL and make sure others are online in your files.  :)
Users online

No users online

Search



Statistics

    Torrents

  • Tracking: 3
  • Todays torrents: 0
  • Seeders: 0
  • Leechers: 0
  • Peers: 0
  • Downloaded: 89.96 GB
  • Uploaded: 9.86 GB

  • Members

  • We have: 838
  • New today: 0
  • Guest today: 9

  • Online

  • Total online: 9
  • Members: 0
  • Guests online: 9
  • Comments: 3
  • Messages: 1,728