PtokaX wiki

Hub (server) for Direct Connect

User Tools

Site Tools


luaapi:px_banman

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
luaapi:px_banman [14/10/2012 04:19] – created ppkluaapi:px_banman [16/06/2015 14:03] (current) ppk
Line 1: Line 1:
-====== Bans manager metatable functions ======+====== Bans manager table functions ======
  
 ^ Function ^ Description ^ ^ Function ^ Description ^
 |BanMan.Save() | Save bans.| |BanMan.Save() | Save bans.|
- +| | |
----- +
 |BanMan.GetBans()|Return table with [[luaapi:ban_table|ban table]]s.| |BanMan.GetBans()|Return table with [[luaapi:ban_table|ban table]]s.|
 |BanMan.GetTempBans()|Return table with [[luaapi:ban_table|ban table]]s.| |BanMan.GetTempBans()|Return table with [[luaapi:ban_table|ban table]]s.|
 |BanMan.GetPermBans()|Return table with [[luaapi:ban_table|ban table]]s.| |BanMan.GetPermBans()|Return table with [[luaapi:ban_table|ban table]]s.|
- +| | |
----- +
 |BanMan.GetBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with ban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with ban(s) for given ip or nil when not exist.| |BanMan.GetBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with ban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with ban(s) for given ip or nil when not exist.|
 |BanMan.GetPermBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with permban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with permban(s) for given ip or nil when not exist.| |BanMan.GetPermBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with permban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with permban(s) for given ip or nil when not exist.|
 |BanMan.GetTempBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with tempban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with tempban(s) for given ip or nil when not exist.| |BanMan.GetTempBan(sNick/sIP)|Return [[luaapi:ban_table|ban table]] with tempban for given nick or nil when not exist. Return table with [[luaapi:ban_table|ban table]](s) with tempban(s) for given ip or nil when not exist.|
- +| | |
----- +
 |BanMan.GetRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.| |BanMan.GetRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.|
 |BanMan.GetTempRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.| |BanMan.GetTempRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.|
 |BanMan.GetPermRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.| |BanMan.GetPermRangeBans()|Return table with [[luaapi:rangeban_table|range ban table]]s.|
- +| | |
----- +
 |BanMan.GetRangeBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangeban for given range or nil when not exist.| |BanMan.GetRangeBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangeban for given range or nil when not exist.|
 |BanMan.GetRangePermBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangepermban for given range or nil when not exist.| |BanMan.GetRangePermBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangepermban for given range or nil when not exist.|
 |BanMan.GetRangeTempBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangetempban for given range or nil when not exist.| |BanMan.GetRangeTempBan(sIPFrom, sIPTo)|Return [[luaapi:rangeban_table|range ban table]] with rangetempban for given range or nil when not exist.|
- +| | |
----- +
 |BanMan.Unban(sNick/sIP)|Unban ban with given nick or ip. Return nil when failed, true if success.| |BanMan.Unban(sNick/sIP)|Unban ban with given nick or ip. Return nil when failed, true if success.|
 |BanMan.UnbanPerm(sNick/sIP)|Unban permban with given nick or ip. Return nil when failed, true if success.| |BanMan.UnbanPerm(sNick/sIP)|Unban permban with given nick or ip. Return nil when failed, true if success.|
 |BanMan.UnbanTemp(sNick/sIP)|Unban tempban with given nick or ip. Return nil when failed, true if success.| |BanMan.UnbanTemp(sNick/sIP)|Unban tempban with given nick or ip. Return nil when failed, true if success.|
- +| | |
----- +
 |BanMan.UnbanAll(sIP)|Unban all bans with given ip.| |BanMan.UnbanAll(sIP)|Unban all bans with given ip.|
 |BanMan.UnbanPermAll(sIP)|Unban all permbans with given ip.| |BanMan.UnbanPermAll(sIP)|Unban all permbans with given ip.|
 |BanMan.UnbanTempAll(sIP)|Unban all tempbans with given ip.| |BanMan.UnbanTempAll(sIP)|Unban all tempbans with given ip.|
- +| | |
----- +
 |BanMan.RangeUnban(sIPFrom, sIPTo)|Unban range ban with given range. Return nil when failed, true if success.| |BanMan.RangeUnban(sIPFrom, sIPTo)|Unban range ban with given range. Return nil when failed, true if success.|
 |BanMan.RangeUnbanPerm(sIPFrom, sIPTo)|Unban permanent range ban with given range. Return nil when failed, true if success.| |BanMan.RangeUnbanPerm(sIPFrom, sIPTo)|Unban permanent range ban with given range. Return nil when failed, true if success.|
 |BanMan.RangeUnbanTemp(sIPFrom, sIPTo)|Unban temporary range ban with given range. Return nil when failed, true if success.| |BanMan.RangeUnbanTemp(sIPFrom, sIPTo)|Unban temporary range ban with given range. Return nil when failed, true if success.|
- +| | |
----- +
 |BanMan.ClearBans()|Clear all bans.| |BanMan.ClearBans()|Clear all bans.|
 |BanMan.ClearPermBans()|Clear all perm bans.| |BanMan.ClearPermBans()|Clear all perm bans.|
 |BanMan.ClearTempBans()|Clear all temp bans.| |BanMan.ClearTempBans()|Clear all temp bans.|
- +| | |
----- +
 |BanMan.ClearRangeBans()|Clear all range bans.| |BanMan.ClearRangeBans()|Clear all range bans.|
 |BanMan.ClearRangePermBans()|Clear all range perm bans.| |BanMan.ClearRangePermBans()|Clear all range perm bans.|
 |BanMan.ClearRangeTempBans()|Clear all range temp bans.| |BanMan.ClearRangeTempBans()|Clear all range temp bans.|
- +| | |
----- +
 |BanMan.Ban(tUser, sReason, sBy, bFull)|Perm ban user IP and Nick. Return nil when failed, true if success.| |BanMan.Ban(tUser, sReason, sBy, bFull)|Perm ban user IP and Nick. Return nil when failed, true if success.|
 |BanMan.BanIP(sIP, sReason, sBy, bFull)|Perm ban given ip. Return nil when failed, true if success.| |BanMan.BanIP(sIP, sReason, sBy, bFull)|Perm ban given ip. Return nil when failed, true if success.|
 |BanMan.BanNick(sNick, sReason, sBy)|Perm ban given nick. Return nil when failed, true if success.| |BanMan.BanNick(sNick, sReason, sBy)|Perm ban given nick. Return nil when failed, true if success.|
- +| | | 
----- +|BanMan.TempBan(tUser, iTime, sReason, sBy, bFull)|Temp ban user IP and Nick. iTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| 
- +|BanMan.TempBanIP(sIP, iTime, sReason, sBy, bFull)|Temp ban given ip. iTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| 
-|BanMan.TempBan(tUser, nTime, sReason, sBy, bFull)|Temp ban user IP and Nick. nTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| +|BanMan.TempBanNick(sNick, iTime, sReason, sBy)|Temp ban given nick. iTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| 
-|BanMan.TempBanIP(sIP, nTime, sReason, sBy, bFull)|Temp ban given ip. nTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| +| | |
-|BanMan.TempBanNick(sNick, nTime, sReason, sBy)|Temp ban given nick. nTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.| +
- +
----- +
 |BanMan.RangeBan(sIPFrom, sIPTo, sReason, sBy, bFull)|Range perm ban given range. Return nil when failed, true if success.| |BanMan.RangeBan(sIPFrom, sIPTo, sReason, sBy, bFull)|Range perm ban given range. Return nil when failed, true if success.|
-|BanMan.RangeTempBan(sIPFrom, sIPTo, nTime, sReason, sBy, bFull)|Range temp ban given range. nTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.|+|BanMan.RangeTempBan(sIPFrom, sIPTo, iTime, sReason, sBy, bFull)|Range temp ban given range. iTime is in minutes (0 = default tempban time from settings) ! Return nil when failed, true if success.|
luaapi/px_banman.1350188373.txt.gz · Last modified: 14/10/2012 04:19 by ppk