Go Back   FlashFXP Forums > > > >

! Requests Need a script or some sort of cool .bat file ? Ask here!

Reply
 
Thread Tools Rate Thread Display Modes
Old 01-05-2004, 01:07 PM   #1
rAWfOX
Senior Member
 
Join Date: Aug 2003
Posts: 148
Default [REQ] Race vs leecherkicking script... ;)

What ive heard is that it aint possible to make souch script... script that will kick all leechers out from a site when a race is started and let them in when the race is done..


But is there any scripter who is willing to do some sort of Race script that atleas kicks the racer out and .. well some kind of smart way .... brainstorm here please
rAWfOX is offline   Reply With Quote
Old 01-05-2004, 01:42 PM   #2
JoeDirt
Junior Member
FlashFXP Registered User
ioFTPD Registered User
 
Join Date: Jul 2003
Posts: 25
Default Re: [REQ] Race vs leecherkicking script... ;)

Quote:
Originally posted by rAWfOX
....some sort of Race script that atleas kicks the racer out and ...
Kick the racer out?
You sure this is what you want? :banana:
JoeDirt is offline   Reply With Quote
Old 01-05-2004, 01:43 PM   #3
rAWfOX
Senior Member
 
Join Date: Aug 2003
Posts: 148
Default

lol... ment the leecher kick the leecher out
rAWfOX is offline   Reply With Quote
Old 01-05-2004, 02:52 PM   #4
Mouton
Posse Member
Ultimate Scripter
ioFTPD Administrator
 
Join Date: Dec 2002
Posts: 1,956
Default

How do u suggest the script could detect the start and the end of a race ?

Kicking leechers is easy.
Keeping ppl from leeching is easy.

Only thing that isn't is detecting start and end events to apply those restrictions.
A site command would be easy for script, but a pain for siteops.
Mouton is offline   Reply With Quote
Old 01-05-2004, 03:02 PM   #5
SomeoneWhoCares_2
Member
 
Join Date: Sep 2002
Posts: 87
Default

it could check for the incomplete symlink = race start
and when its gone = race end
SomeoneWhoCares_2 is offline   Reply With Quote
Old 01-05-2004, 05:06 PM   #6
tuff
Senior Member
FlashFXP Registered User
ioFTPD Scripter
 
Join Date: Jan 2003
Posts: 277
Default

and if the release is incomplete for 3 days?
__________________
#iotools #ioftpd (both on efnet)
tuff is offline   Reply With Quote
Old 01-05-2004, 07:11 PM   #7
SomeoneWhoCares_2
Member
 
Join Date: Sep 2002
Posts: 87
Default

Quote:
Originally posted by tuff
and if the release is incomplete for 3 days?
of course the script will have a max incomplete time option

or if there was an autonuke script
SomeoneWhoCares_2 is offline   Reply With Quote
Old 01-06-2004, 03:44 AM   #8
FTPServerTools
Senior Member
FlashFXP Beta Tester
ioFTPD Scripter
 
Join Date: Sep 2002
Posts: 543
Default

I dont think that that is so hard. Using the following defenitions:
RACE=x or more users in the same dir and uploading
RACE COMPLETE=completion tag available
RACE PASSED=last file uploaded from race>y minutes ago or race dir created y minutes ago
KICK=immediate removal frmo the site

now loop in a who loop, so say once every 10 seconds in a timer loop. So since there is no timer available in the tcl script you would need an external program to start the thing OR you need to put it on the file download trigger (preferred solution if you use tcl).
Assuming you take the STOR pre command:
Find race occuring:
Code:
for all connections to io do
  store user,connection,path,action in the who_list
for all connection(i) in the who_list
  for all connection(j) in the who_list
    if i!=j and action(i)==uploading and action(j)==uploading and path(i)==path(j) then {
      race=TRUE;
      racepath(i)=path(i);
    }
  next j
next i

if (race) then
  store(race,now)
  for all action(i) do
    if action(i)!=uploading then kill connection(i)   //simple kill all leechers or alternatively use sitekill transfer=down
  next i    
end if

Put on the post STOR command:
for all connections to io do
  store user,connection,path,action in the who_list
race=false
for all connections to io do
  if action(i)=uploading and completiontag(path(i)) then race=true
store(race,now)


Put on the RETR pre command to disallow RETR during a race.
fetch(race)
fetch(racestart)
if race and now-racestart>x minutes then return not allowed
race=false
store(race,now)


Alternatively as extra:
Put on the LOGIN pre command to disallow LOGIN during a race.
fetch(race)
fetch(racestart)
if race and now-racestart>x minutes then return not allowed
race=false
store(race,now)

Now simply convert this stuff to itcl or an external C program and you got your script.
FTPServerTools is offline   Reply With Quote
Reply

Tags
brainstorm, kicks, race, script, scripter

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Download grinding to a halt bruceh General Discussion 6 09-07-2004 08:29 AM


All times are GMT -5. The time now is 05:20 AM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)