Problem in the script 2
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

Problem in the script 2

Started by Genius, 12 September, 2005, 22:10:57

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Genius

Hi ppl

I have a problem in this script


--## Iniciu do Script LUA 5 ##--
--## Script adaptado DvdRip.sytes.net por [NT]Genius ##--


kb = 1024
mb = 1024 ^ 2
gb = 1024 ^ 3

MinShare = 10240*mb -- in MBs
MinSlots = 3
MaxHubs = 6
tImmune = { ["[SP]????r??h??"] = 1, ["[SP]_minimal_man_"] = 1, ["[TL]TheThunder"] = 1, ["[SP]-?DiOsPiRo?-"] = 1, ["[TVT](???fLuSh???)"] = 1, ["[SP]????????r??"] = 1 } --## Non-Operators Immune List (["nick"] = 1) ##--

DoShareUnits = function(intSize)
   if intSize ~= 0 then
      local tUnits = { "Bytes", "KB", "MB", "GB", "TB" }
      intSize = tonumber(intSize);
      local sUnits;
      for index = 1, table.getn(tUnits) do
         if(intSize < 1024) then sUnits = tUnits[index]; break; else intSize = intSize / 1024; end
      end
      return string.format("%0.1f %s",intSize, sUnits);
   else
      return "nothing"
   end
end

ConnectToMeArrival = function(curUser,data)
   if not curUser.bOperator then
      if not tImmune[curUser.sName] then
         if curUser.iShareSize < MinShare then
            return curUser:SendPM("*** --=( Boas, voss? tem pouca partilha. O minimo ? de [ "..DoShareUnits(MinShare).." ] = [ 10gb ]. Abra o seu espirito de partilha, e d? mais algum contributo. At? l? ficar? impossibilitado de efectuar downloads. )=--  --=( DvdRip.sytes.net )=--"),1
         elseif curUser.iSlots < MinSlots then
            return curUser:SendPM("*** --=( Boas, voss? tem poucas slots abertas. O minimo ? de "..MinSlots.." slots. Abra 3 a 5 slots para puder efectuar downloads no Hub. )=--  --=( DvdRip.sytes.net )=--"),1
         elseif (curUser.iNormalHubs + curUser.iRegHubs) > MaxHubs then
            return curUser:SendPM("*** --=( Boas, Voss? esta ligado a demasiados Hubs. O limite maximo ? de "..MaxHubs..". Pf Desligue-se de alguns. At? l? fica impossibilitado de efectuar downloads. )=--  --=( DvdRip.sytes.net )=--"),1
         end
      end
   end
end

RevConnectToMeArrival = ConnectToMeArrival

--## Fim do Script LUA 5 ##--



Ppl no receive this messages


curUser:SendPM("*** --=( Boas, voss? tem pouca partilha. O minimo ? de [ "..DoShareUnits(MinShare).." ] = [ 10gb ]. Abra o seu espirito de partilha, e d? mais algum contributo. At? l? ficar? impossibilitado de efectuar downloads. )=--  --=( DvdRip.sytes.net )=--"),1
         elseif curUser.iSlots < MinSlots then
            return curUser:SendPM("*** --=( Boas, voss? tem poucas slots abertas. O minimo ? de "..MinSlots.." slots. Abra 3 a 5 slots para puder efectuar downloads no Hub. )=--  --=( DvdRip.sytes.net )=--"),1
         elseif (curUser.iNormalHubs + curUser.iRegHubs) > MaxHubs then
            return curUser:SendPM("*** --=( Boas, Voss? esta ligado a demasiados Hubs. O limite maximo ? de "..MaxHubs..". Pf Desligue-se de alguns. At? l? fica impossibilitado de efectuar downloads. )=--  --=( DvdRip.sytes.net )=--"),1


Please chenge the script cod and make a new

EX: user login in the hub and receive this

Hi user xxx your ip is xxx your share is xxx
You need open 3 slots and max hub 6
God downloads

Sory about my bad inglish

Genius

Hi

Please make this too in the script

ex:

Min version dc++
min version odc
min version strongdc
min version ldc++

If user dont have the min version dc cant downloads. and receive a message on login

Its possible make this?

SMF spam blocked by CleanTalk