TriJob Anti Cheat (simple)

Results 1 to 14 of 14
  1. #1
    Member Syloxx is offline
    MemberRank
    Aug 2014 Join Date
    GermanyLocation
    68Posts

    TriJob Anti Cheat (simple)

    Hey folks,
    I wanna release a simple version of my anti cheat query (no error handlers etc).


    Query description:
    on trader goods pickup the query check if the character is thief and his location is in town while he pick up
    if so then the item he picked up get removed. (takes effect after teleport).


    Code:
        /**_# TriJob Anti Cheat by Syloxx (simple)*/
        IF @operation = 144
        BEGIN
            DECLARE @JobType tinyint
                , @IsBattleField bit
                , @ItemID int
    
    
            SELECT @JobType = CTJ.JobType
                , @IsBattleField = R.IsBattleField
            FROM SRO_VT_SHARD.dbo._Char C
                INNER JOIN SRO_VT_SHARD.dbo._CharTriJob CTJ ON C.CharID = CTJ.CharID
                INNER JOIN SRO_VT_SHARD.dbo._RefRegion R ON C.LatestRegion = R.wRegionID
            WHERE C.CharID = @CharID
    
    
            IF @JobType = 2 AND @IsBattleField = 0
            BEGIN
                SELECT @ItemID = ID64
                FROM SRO_VT_SHARD.dbo._Items
                WHERE Serial64 = @ItemSerial
    
    
                UPDATE SRO_VT_SHARD.dbo._InvCOS
                SET ItemID = 0
                WHERE ItemID = @ItemID
    
    
                /*
                INSERT INTO _AntiCheatLog
                VALUES  @CharID, @ItemSerial, GETDATE())
                */
            END
        END

    Tutorial:
    -Add this query to the bottom of your _AddLogItem procedure.


    Don't remove the header comment!
    Press thanks if you use this query!


  2. #2
    Apprentice Pure3viL is offline
    MemberRank
    Feb 2014 Join Date
    22Posts

    Re: TriJob Anti Cheat (simple)

    keep sharing :P

  3. #3
    No avatar RenePunik is offline
    MemberRank
    Feb 2013 Join Date
    1,430Posts

    Re: TriJob Anti Cheat (simple)

    Thanks appreciate your work, but where is _AntiCheatLog table? (just a mention)

  4. #4
    Member Syloxx is offline
    MemberRank
    Aug 2014 Join Date
    GermanyLocation
    68Posts

    Re: TriJob Anti Cheat (simple)

    i commented the insert function because it didn't released the table, if you want this function just add the table and uncomment it

  5. #5
    No avatar RenePunik is offline
    MemberRank
    Feb 2013 Join Date
    1,430Posts

    Re: TriJob Anti Cheat (simple)

    Quote Originally Posted by Syloxx View Post
    i commented the insert function because it didn't released the table, if you want this function just add the table and uncomment it
    Sorry, haven't seen that. Anyway thanks :P

  6. #6
    Novice kox2030 is offline
    MemberRank
    Oct 2013 Join Date
    4Posts

    Re: TriJob Anti Cheat (simple)

    thanks

  7. #7
    No avatar RenePunik is offline
    MemberRank
    Feb 2013 Join Date
    1,430Posts

    Re: TriJob Anti Cheat (simple)

    After test, it doesn't works... I have picked up the trade items from ground then teleported to thief town and opened my cos's inventory and nothing was deleted. Just wonderful what's job of this value
    Code:
    IF @operation = 144
    Isn't it should be "114" instead of "144"
    Last edited by RenePunik; 16-03-15 at 07:45 PM.

  8. #8
    Member Syloxx is offline
    MemberRank
    Aug 2014 Join Date
    GermanyLocation
    68Posts

    Re: TriJob Anti Cheat (simple)

    Quote Originally Posted by RenePunik View Post
    After test, it doesn't works... I have picked up the trade items from ground then teleported to thief town and opened my cos's inventory and nothing was deleted. Just wonderful what's job of this value
    Code:
    IF @operation = 144
    Isn't it should be "114" instead of "144"
    thanks, if some1 else can agree this i'll change the operation i cant test it yet

    btw create another check IF @operation = 114 (144) AND @IemRefID in _RefObjCommon where TypeID3 = xxx AND TypeID4 = xxx

    otherwise this query will delete items from grab pet since it uses the same Operation

  9. #9
    Novice TheRock2015 is offline
    MemberRank
    Feb 2015 Join Date
    3Posts

    Re: TriJob Anti Cheat (simple)

    I agree with RenePunik that it doesn't work. could you check sql codes please.

  10. #10
    No avatar RenePunik is offline
    MemberRank
    Feb 2013 Join Date
    1,430Posts

    Re: TriJob Anti Cheat (simple)

    Missing Table:
    Code:
    USE [SRO_VT_SHARDLOG]
    GO
    
    /****** Object:  Table [dbo].[_AntiJobCheatLog]    Script Date: 3/17/2015 9:58:09 AM ******/
    SET ANSI_NULLS ON
    GO
    
    SET QUOTED_IDENTIFIER ON
    GO
    
    CREATE TABLE [dbo].[_AntiJobCheatLog](
        [CharID] [int] NOT NULL,
        [ItemSerial] [bigint] NOT NULL,
        [Date] [date] NOT NULL,
     CONSTRAINT [PK__AntiJobCheatLog] PRIMARY KEY CLUSTERED 
    (
        [CharID] ASC
    )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
    ) ON [PRIMARY]
    
    GO
    And don't forget to uncomment this line: just delete /* & */
    Code:
                /*
                INSERT INTO _AntiCheatLog
                VALUES   @CharID, @ItemSerial, GETDATE())
                */
    - - - Updated - - -

    At least it doesn't works, we need fix!

  11. #11
    Proficient Member tschulian is offline
    MemberRank
    Jul 2012 Join Date
    ErlangenLocation
    151Posts

    Re: TriJob Anti Cheat (simple)

    Nah, dont use TypeIDs, better use the Item IDs of all _TRADE Items.




    Edited and fixed _AddLogItem extension
    Get the whole code here http://pastebin.com/Zgk5UbSJ due to the auto converting of RZ I cannot post the code correctly.
    PHP Code:
    http://pastebin.com/Zgk5UbSJ 
    Lol, RZ Changes things like @operation and @CharID to a Mention thing ...... -.-





    I just checked this procedure out, and I found out sometimes it deletes the trade items, and sometimes not.
    I'll take care about and i'll post a hotfix soon.
    Last edited by tschulian; 24-04-15 at 02:23 PM.

  12. #12
    No avatar RenePunik is offline
    MemberRank
    Feb 2013 Join Date
    1,430Posts

    Re: TriJob Anti Cheat (simple)

    Thanks tschulian

  13. #13
    Apprentice yxc001 is offline
    MemberRank
    Jan 2013 Join Date
    20Posts

    Re: TriJob Anti Cheat (simple)

    Quote Originally Posted by tschulian View Post
    Nah, dont use TypeIDs, better use the Item IDs of all _TRADE Items.




    Edited and fixed _AddLogItem extension
    Get the whole code here http://pastebin.com/Zgk5UbSJ due to the auto converting of RZ I cannot post the code correctly.
    PHP Code:
    http://pastebin.com/Zgk5UbSJ 
    Lol, RZ Changes things like @operation and @CharID to a Mention thing ...... -.-





    I just checked this procedure out, and I found out sometimes it deletes the trade items, and sometimes not.
    I'll take care about and i'll post a hotfix soon.
    jup but there is one problem, if there are custom trader goods then your list is incomplete.

  14. #14
    Member Syloxx is offline
    MemberRank
    Aug 2014 Join Date
    GermanyLocation
    68Posts

    Re: TriJob Anti Cheat (simple)

    Quote Originally Posted by tschulian View Post
    I just checked this procedure out, and I found out sometimes it deletes the trade items, and sometimes not.
    I'll take care about and i'll post a hotfix soon.
    The pos in _Char isnt live (it have some delay) would be useless to update the _Char table everytime if the char moves this is why this happen.
    I didn't really checked what is the best possible way this is why i used the most simple way.

    Maybe the charpos appear if you pick goods / use bandit scroll
    i just released the logic behind it.



Advertisement