[Mini Release] Custom IP/HWID Limit By Query!

09/30/2023 22:28 øNovaTeaMø#1
[Only registered and activated users can see links. Click Here To Register...]
This Is Mini Release (Of My Old Bad Codes)

This Make Custom IP/HWID Limit By Query / RegionID

Maybe anyone can enjoy it or improve this query...

Note: You can add Job Hwid Using Select ItemID From _Inventory From Slot When Not=0 (Player Using Cape) and add this on ADDLOGCHAR or in Producer !
Alot New Things Can Be added on this query good luck!

Note2: Can be used on Filter Spawn Packet... (By Execute Query CharID!)

This query working fine for me!

-------------------------------------------------------------------
--Create Table!
--1°
-------------------------------------------------------------------

HTML Code:
USE [YOUR DB]
GO

/****** Object:  Table [dbo].[CustomPcLimit]    Script Date: 30/09/2023 17:14:01 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[CustomPcLimit](
	[RegionID] [int] NOT NULL,
	[IPCount] [int] NOT NULL,
	[HWIDCount] [int] NULL
) ON [PRIMARY]
GO
-------------------------------------------------------------------
--PRODUCER!
--2°
-------------------------------------------------------------------

HTML Code:
USE [YOURDB]
GO
/****** Object:  StoredProcedure [dbo].[CustomPcLimitSystem]    Script Date: 30/09/2023 17:15:59 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[CustomPcLimitSystem]
@CharID int
AS
DECLARE @Region int = (Select LatestRegion From SRO_VT_SHARD.._Char Where CharID=@CharID)
Declare @RegionLimit int = (Select RegionID From YOURDB..CustomPcLimit Where @Region=RegionID)
Declare @RegionCount int = (Select Count(LatestRegion) From SRO_VT_SHARD.._Char Where LatestRegion=@Region)
Declare @LimitIP int = (Select [IPCount] From YOURDB..CustomPcLimit Where @Region=RegionID)
Declare @LimitHWID int = (Select [HWIDCount] From YOURDB..CustomPcLimit Where @Region=RegionID)
Declare @CharName varchar(max) = (Select CharName16 From SRO_VT_SHARD.._Char WHere CharID=@CharID)
DECLARE @IP varchar(max) = (Select [IP] From YOURDB.._Players Where @RegionCount=@LimitIP and CharID=@CharID)
DECLARE @Hwid varchar(max) = (Select [HWID] From YOURDB.._Players Where @RegionCount=@LimitHWID and CharID=@CharID)
Declare @CountIP int = (Select Count(ip)+1 From YOURDB.._Players Where IP=@IP)
Declare @CountHwid int =  (Select Count(HWID)+1 From YOURDB.._Players Where HWID=@Hwid)

--IP LIMIT
If (@Region=@RegionLimit and @CountIP+1=@LimitIP+1 or @CountIP+2=@LimitIP+2 or @CountIP+3=@LimitIP+3)
begin
insert Into _AutoNotice Values ('Sorry You Reached Max IP Limit!',@CharName,0,'00:00:00')
insert into YOURDB.._InstantTeleportDelivery values (@CharID,1,1,25000,982,140,140)
end

--PC LIMIT
If (@Region=@RegionLimit and @CountHwid+1=@LimitHWID+1 or @CountHwid+2=@LimitHWID+2 or @CountHwid+3=@LimitHWID+3)
begin
insert Into _AutoNotice Values ('Sorry You Reached Max Hwid Limit!',@CharName,0,'00:00:00')
insert into YOURDB.._InstantTeleportDelivery values (@CharID,1,1,25000,982,140,140)
end
-------------------------------------------------------------------
--ADDLOGCHAR (CAN ADD EVENTID=4 and EVENTID=6)
--3°
-------------------------------------------------------------------

HTML Code:
IF @EventID=11 or @EventID=9
	begin
	WAITFOR DELAY '00:00:05' --CHECK TIME
	Exec YOUR DB..CustomPcLimitSystem @CharID
	END

--Credits. DeeGhosTaP
10/02/2023 05:22 VORTEX*#2
what ??? :cry:
10/03/2023 22:07 øNovaTeaMø#3
Quote:
Originally Posted by VORTEX* View Post
what ??? :cry:
this query have pc/ip limit sistem working by regionID

you can use PC per RegionID...

have filters don't have custom regionid pc limit!

and its old codes but work fine i used this code on 2015...

and if you don't have pc limit you can use IP limit for any regionID and make only 1 enter on this!

not its good release its only more any thing shared, maybe useful for anyone or not...
i only share it...
10/04/2023 00:08 Yarken1337#4
Old but gold i did a one like it in past but good work my friend and thank you for share it
10/04/2023 12:35 gmhasan13#5
Stop insulting people and learn to share things, thank you bro, nice post
10/04/2023 19:49 NorseGodTyr#6
Quote:
Originally Posted by øNovaTeaMø View Post
this query have pc/ip limit sistem working by regionID

you can use PC per RegionID...

have filters don't have custom regionid pc limit!

and its old codes but work fine i used this code on 2015...

and if you don't have pc limit you can use IP limit for any regionID and make only 1 enter on this!

not its good release its only more any thing shared, maybe useful for anyone or not...
i only share it...

:facepalm: Many filters have already HWID/IP limit by region since xx years
10/04/2023 21:06 øNovaTeaMø#7
Quote:
Originally Posted by NorseGodTyr View Post
:facepalm: Many filters have already HWID/IP limit by region since xx years
yeah i now objetive here its for very newbie on silkroad or anything same...

and not its all filter have custom hwid per region, 50% of filter countain only pc limit only for selected region fw,ctf,ba etc... but not for region custom example... (dungeons new like Frozen dungeon etc...)

and have alot people editing silkroad today not know C# or C++


I'm not forcing anyone to use it nor do I expect you to like it, I just threw it in the community, it could be useful to someone, that's all!
10/08/2023 14:54 zxvoyeu2#8
this man is living in 1977 :feelsbadman:
10/12/2023 21:38 T0o0P#9
Thanks