John Smith Posted July 13, 2014 Posted July 13, 2014 hi im blocking a country but i want to let my friend play(he's an exception) heres my code local countries = { [ "PT" ] = true } local serials = { [ "B1E80345047CC71F1F5C427C581C4D94" ] = true } function paises ( ) local gCountry = exports.admin:getPlayerCountry ( source ) or "N/A" local gSerial = getPlayerSerial ( source ) if ( serials [ gSerial ] ) then outputChatBox("welcome mike",source) else if ( countries [gCountry] then kickPlayer ( source, "Country not allowed." ) end end end addEventHandler ( "onPlayerJoin", getRootElement(), paises ) it doesnt kick him if serial doesnt match,and it doesnt kick him if hes from portugal without that serial please help If you find my post useful or if it helped you, please like my post Ingame name: ZoeN
John Smith Posted July 13, 2014 Author Posted July 13, 2014 still doesnt work If you find my post useful or if it helped you, please like my post Ingame name: ZoeN
Max+ Posted July 13, 2014 Posted July 13, 2014 still doesnt work --ServerSide , local countries = { [ "PT" ] = true } local serials = { [ "B1E80345047CC71F1F5C427C581C4D94" ] = true } function paises ( ) local gCountry = exports.admin:getPlayerCountry ( source ) or "N/A" local gSerial = getPlayerSerial ( source ) if ( serials [ gSerial ] ) then outputChatBox("welcome mike",source) elseif ( countries [gCountry] ) then kickPlayer ( source, "Country not allowed." ) end end addEventHandler ( "onPlayerJoin", getRootElement(), paises ) Make sure you add the resource in acl admin . - New , Kill System - New, GameMode Intro - Leve / Exp System - New nametag showing style - New , Hud For Players - Skin Selection from SA-MP - Money System / Buy Weapons - Drop Weapons - New, Flood System - New , Group Assign - Gun license For Weapons - Random Rule System For Money
John Smith Posted July 13, 2014 Author Posted July 13, 2014 thanks max If you find my post useful or if it helped you, please like my post Ingame name: ZoeN
Max+ Posted July 13, 2014 Posted July 13, 2014 thanks max You're welcome - New , Kill System - New, GameMode Intro - Leve / Exp System - New nametag showing style - New , Hud For Players - Skin Selection from SA-MP - Money System / Buy Weapons - Drop Weapons - New, Flood System - New , Group Assign - Gun license For Weapons - Random Rule System For Money
Guest Posted August 19, 2015 Posted August 19, 2015 please i wan't to block country but idk how can any one help me
JR10 Posted August 21, 2015 Posted August 21, 2015 Just take a look at the OP's code? Business System viewtopic.php?f=108&t=35797 Notepad++ Syntax Highlighting & Auto Completion viewtopic.php?f=91&t=76726 SQLite Tutorial viewtopic.php?f=148&t=38203
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now