need help find script GeoIp To LUA 5.1
 

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

need help find script GeoIp To LUA 5.1

Started by TrIp-iN-SuN, 18 August, 2006, 16:05:44

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

TrIp-iN-SuN

same one can to convert geoip from lua5.0 to lua 5.1 or make new one?

[HE]Newbie

You can convert it yourself probably, with Mutor's Lua50to51 script, if you have any problems just post it here but i think its fair that you try it your own

Greetz [NL][Newbie][NL]
There will be 1 day, that i learn

nlgezel.hopto.org:411

TrIp-iN-SuN

#2
i try and it's don't work i get this error
Syntax ...s and Settings\TrIp-iN-SuN\Desktop\Copy of Psy Mission\scripts\geoip.lua:1: 'end' expected near '<eof>'

in that script
Code: lua
function Main()
    nr = 10 --<------Numbers of "Toppers" You want to show
    f = {}
    tCnumb = {}
    CountryCode = "ALL"--<--- the default value
    OpConnected = NewUserConnected
    OpDisconnected = UserDisconnected
   ) dofile("Files/Func/fFunc.lua")
   ) dofile("Files/Func/pCommand.lua")
   ) dofile("Files/Saves/Cnumb.txt")
        if frmHub:GetUsersCount() == 0 then
        tCnumb={}
        end
end

function OnExit()
    return f.save("Files/Saves/Cnumb.txt", tCnumb)
end

function ChatArrival(User, msg)
    local _,_,cmd,arg = string.find( msg, "^%b<>%s(%S+)%s?(%S*)|$" )
        if cmd and pCommand[cmd] then return pCommand[cmd](User, arg) end
end

function NewUserConnected(User)
    return f.Newcon(User)
end

function UserDisconnected(User)
    return f.UserDisc(User)
end


Herodes

Why don't you point the file-script you want to convert ?

Alexinno

I think GeoIP-0.7a.lua works with Px Lua 5.1.1 too , you could try it ;)

Psycho_Chihuahua

Quote from: TrIp-iN-SuN on 19 August, 2006, 12:55:12
Syntax ...s and Settings\TrIp-iN-SuN\Desktop\Copy of Psy Mission\scripts\geoip.lua:1: 'end' expected near '<eof>'

that means there is an 'end' missing in the script
PtokaxWiki ?PtokaX Mirror + latest Libs

01100001011011000111001101101111001000000110101101101110011011110111011101101110001000000110000101110011001000000101010001101111011010110110111101101100011011110111001101101000

UwV

i dont remeber me changing anything in this version .. but here you go..
Code: lua
--// GeoIP V 0.7a by Mogli //--
--// Rescripted Version of GeoIP from VidFamne //--

--// "This product runs with GeoIP data created by MaxMind, available from http://maxmind.com/" //--

--// You may use/copy/edit this code, but you may never compile one single bit of it //--
--// Open code rocks, I am not ashaimed of my sloppy coding :), I like it //--
--// Try to compile your words and then try to make yourself understood //--
--// Open Code is like sharing thaughts, and as we know sharing is caring, feels good //--


--// INSTALLATION //--
-- This script must run as last script, and all other scripts, must return 1 after user:Disconnect() in NewUserConnected()

--// CHANGELOG //--

-- V 0.7a
-- Top online Countries added ( Idea from UwV )
-- Added Saving All Stats to file ( requested by UwV )

-- V 0.7 ( NOTE, due to changes please delete the file "GeoIPDB.txt", then restart scripts )
-- Removed TSDB, without memory boost but way better perfomance :)
-- Rewritten IPBot to speed up loading and saving and keep up performance

-- V 0.6b
-- Added option for OPs/Masters to be immune and bypass any security check, by default enabled to set immune profiles check for GeoIP._ImmuneProfs
-- Added showing of countrycode at get country by nick and by ip
-- Some grammar updates and visual updates in the edit section

-- V 0.6a 12.09.05
-- Fixed error on IP's that where not in the db, check the IPBot for details ( thx for mentioning it Mike )
-- Date now shows like "September the 11th '05"

-- V 0.6 - 18.7.05
-- NOTE: Due to changes you need to deleted these files "GeoIPDB.txt" and "CountryList.txt", and then restart scripts
-- Added, option to set UserLimit for 'Other', meaning that all other countries, not in the list are considered 'Other', cmd: countrylimit Other <limit>
-- Added CountryCode to DB, and option to force user to have [cc]nick as their nick, requested by the_pest, check for GeoIP._forcecc
-- Fixed some stupid errors

-- V 0.5a - 6.7.05
-- Optimised Parsing of MaxMind GeoIP DB, since file has binary format

-- V 0.5 -  5.7.05
-- Optimised Online User Table, script needs to run as last script and other scripts before GeoIP, must return 1 if it disconnects  a user during NewUserConnected
-- Added Userlimit/Country, reuqested by the_pest, when limit is 0 then it is removed
-- Command get UserCountry, will now only check the onlinelookuptable, for that user ( faster )
-- Added Option to set Command Prefixes, requested by UwV

-- V 0.4 -  2.7.05
-- Fixed: Online user listing, keep onlineuser lookuptable idea by UwV :), should be more acurate maby wrong by one or two, but not growing
-- and one can store the country, so it must not be searched again on disconnect :), little speed tweaking
-- added Disconnect if not in GeoIP DB, check for 'GeoIP._DisconnectOnNotGeoIP', by default it is disabled, enable it, if you use GeoIP to only let in certain countries
-- added testing sequence, set dotest in Main to 1 e.g.  dotest = 1
-- added table for Countries, so list only is updated once on script start ( may take some while loading, but only once, then it reads from file CountryList.txt )

-- V 0.3 - 27.6.2005
-- Fixed: Showonline, when country has 0 users it is removed from list
-- Added Saving Of Stats and command to clear stats
-- Added Max Online Stats
-- Master: Command: Add/Del Allow Countries (Only by Countryname and not by Countrycode)
-- Master: Command: Add/Del Disallow Countries (Only by Countryname and not by Countrycode)
-- Master: Command: List Available Countries

-- V 0.2
-- Stripped from VidFamnes GeoIP

-- // Stats //-- 

-- Tested on 1 GHz ( Bot is now almost 20 times faster )
-- GeoIP-0.7: CVS: Added Ranges: 74040 
-- GeoIP-0.7: CVS: Time used: 6.3910 seconds   avg; 0.0001 
-- GeoIP-0.7: Tested 1000 UserConnects & Disconnects in 0.06300 secs. avg: 0.00006 
-- IP-Bot: Tested 100000 Lookups in 4.62500 secs. avg: 0.00005 
-- Load Ranges: 0.875 

-- GeoIP-0.6: Tested 1000 UserConnects in 1.07800 secs. avg: 0.00108 on 2.0 GHz mem 6900 kb
-- GeoIP-0.5b: Tested 1000 UserConnects in 0.98400 secs. avg: 0.00098 on 2.0 GHz mem 6900 kb
-- GeoIP-0.5a: Tested 1000 UserConnects in 0.98400 secs. avg: 0.00098 on 2.0 GHz mem 6547 kb
-- GeoIP-0.5a: CVS: Added Ranges: 74161 
-- GeoIP-0.5a: CVS: Time used: 7.8750 seconds   avg; 0.0001 on 2.0 GHz
-- GeoIP-0.5: Tested 1000 UserConnects in 0.56300 secs. avg: 0.00056 on 2.4 GHz, Mem: 6546 kb
-- GeoIP-0.4: Tested 1000 Connects in 0.62500 secs. avg: 0.00063 on 2.4 GHz

incase i did change somehting ..
well .. get attachment since the scripts is too big for posting..
\NL   The knowledge and skills you have achieved are meant to be forgotten so you can float comfortably in emptiness, without obstruction.
" Holly loves me,...  . "      ;o)

& don't forget, the motto is :
  -- SUPPORT YOUR LOCAL DJ'S --

modular

Quote from: UwV on 19 August, 2006, 14:37:24
i dont remeber me changing anything in this version .. but here you go..

you bloody hippie  being all nice and all    ;)  ... 

TrIp-iN-SuN

how i changed too all users allwoed to enter becose no one can't to enter to hub?

UwV

#9
Quote from: modular on 19 August, 2006, 18:47:55
you bloody hippie  being all nice and all    ;)  ... 

Quote from: TrIp-iN-SuN on 20 August, 2006, 14:55:57
how i changed too all users allwoed to enter becose no one can't to enter to hub?
nice but not that nice  modular
and not a hippie, a freak maybe but not a hippie ..     ;)   
well TrIp-iN-SuN i guess you are missing some files etc. and you need to get the rest of the geo ip script somewhere on this board .. look for : GeoIP V 0.7a by Mogli
\NL   The knowledge and skills you have achieved are meant to be forgotten so you can float comfortably in emptiness, without obstruction.
" Holly loves me,...  . "      ;o)

& don't forget, the motto is :
  -- SUPPORT YOUR LOCAL DJ'S --

Psycho_Chihuahua

PtokaxWiki ?PtokaX Mirror + latest Libs

01100001011011000111001101101111001000000110101101101110011011110111011101101110001000000110000101110011001000000101010001101111011010110110111101101100011011110111001101101000

TrIp-iN-SuN

to umv i have this virion but don't find where i can open to all users

UwV

as far as i know it is open to all users by default .. try a fresh instal of the script and all files.
\NL   The knowledge and skills you have achieved are meant to be forgotten so you can float comfortably in emptiness, without obstruction.
" Holly loves me,...  . "      ;o)

& don't forget, the motto is :
  -- SUPPORT YOUR LOCAL DJ'S --

SMF spam blocked by CleanTalk