Raised This Month: $ Target: $400
 0% 

[L4D2/TF2] VScript


Post New Thread Reply   
 
Thread Tools Display Modes
Author
FortyTwo
New Member
Join Date: Dec 2020
Plugin ID:
8504
Plugin Version:
Plugin Category:
Technical/Development
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    24 
    Plugin Description:
    Exposes many VScript features into SourceMod
    Old 06-25-2023 , 09:30   [L4D2/TF2] VScript
    Reply With Quote #1

    Description
    SourceMod plugin that exposes many VScript features to make use of it.
    Currently supports L4D2 and TF2. More game support can be added to gamedata if requested.

    Features
    You can read all features plugin has at vscript.inc, but some noticeable features include:
    • Creating SDKCall and DynamicDetour handle from native function, with parameter and return infos auto filled. Do not need gamedata signature for address of function.
    • Creating new native function for vscript to use.
    • Managing with HSCRIPT objects.
    • Compiling and Executing a vscript code with parameters and returns passed.

    You can find some code examples in readme.

    ConVars
    • vscript_version: Current version, no touchie.

    Dependencies
    Source Code
    All build package for download

    Last edited by FortyTwo; 03-19-2024 at 17:23.
    FortyTwo is offline
    feedays
    New Member
    Join Date: Nov 2018
    Old 06-26-2023 , 16:19   Re: [CS:GO/L4D2/TF2] VScript
    Reply With Quote #2

    NOOB question: Any chance this could be made to work in HL2DM?

    thank you in advance.
    feedays is offline
    FortyTwo
    New Member
    Join Date: Dec 2020
    Old 06-26-2023 , 18:38   Re: [CS:GO/L4D2/TF2] VScript
    Reply With Quote #3

    Quote:
    Originally Posted by feedays View Post
    NOOB question: Any chance this could be made to work in HL2DM?

    thank you in advance.
    HL2DM game does not have vscript built in, so no it's not possible to do so.
    FortyTwo is offline
    Gazyi
    Junior Member
    Join Date: Apr 2016
    Old 01-04-2024 , 11:10   Re: [CS:GO/L4D2/TF2] VScript
    Reply With Quote #4

    Thanks, it's very useful.
    But I don't get how to bind plugin function to VScriptFunction. All examples are about setting empty function and then detouring/hooking it. Is that the only way to do that? Maybe it's possible to call plugin function directly?
    Gazyi is offline
    FortyTwo
    New Member
    Join Date: Dec 2020
    Old 03-19-2024 , 17:32   Re: [CS:GO/L4D2/TF2] VScript
    Reply With Quote #5

    Quote:
    Originally Posted by Gazyi View Post
    Thanks, it's very useful.
    But I don't get how to bind plugin function to VScriptFunction. All examples are about setting empty function and then detouring/hooking it. Is that the only way to do that? Maybe it's possible to call plugin function directly?
    Whoops I rarely read posts here, sorry for late reply.

    But yes, you are correct that detouring is the only way to have vscript able to directly call a plugin function. I'm not sure exactly what you're suggesting to have, when detouring has all of the possibilities you can do with it.
    FortyTwo is offline
    Spirit_12
    Veteran Member
    Join Date: Dec 2012
    Location: Toronto, CA
    Old 07-08-2024 , 14:01   Re: [L4D2/TF2] VScript
    Reply With Quote #6

    This is amazing. Especially the ability to create new natives for vscript.

    This will help me a ton in fixing some of the map logic.
    __________________
    Spirit_12 is offline
    Mystik Spiral
    Senior Member
    Join Date: Oct 2020
    Location: Orlando, FL
    Old 09-12-2024 , 19:54   Re: [L4D2/TF2] VScript
    Reply With Quote #7

    @FortyTwo

    Although the source is available on your GitHub page, the Packages -> Artifacts zip file, like this, only contain the include files, not the source to build vscript.smx. Is that intentional?

    To be clear, the latest source compiles and the vscript.smx is created without any problem. I was just pointing out the source code is not in the artifacts file.
    __________________

    Last edited by Mystik Spiral; 09-12-2024 at 20:17.
    Mystik Spiral is offline
    Mi.Cura
    Veteran Member
    Join Date: Dec 2016
    Location: Brazil
    Old 09-13-2024 , 10:12   Re: [L4D2/TF2] VScript
    Reply With Quote #8

    Or what's different from this one?

    https://forums.alliedmods.net/showthread.php?t=318024]
    __________________
    Mi.Cura | Modded Servers | L4D2
    https://steamcommunity.com/groups/micuramodzombie
    Mi.Cura is offline
    Spirit_12
    Veteran Member
    Join Date: Dec 2012
    Location: Toronto, CA
    Old 09-13-2024 , 12:27   Re: [L4D2/TF2] VScript
    Reply With Quote #9

    Quote:
    Originally Posted by Mi.Cura View Post
    One is for replacing vscript files, while this one allows you to create new vscript native functions which can be used in the scripts.
    __________________
    Spirit_12 is offline
    Mi.Cura
    Veteran Member
    Join Date: Dec 2016
    Location: Brazil
    Old 09-13-2024 , 13:19   Re: [L4D2/TF2] VScript
    Reply With Quote #10

    Quote:
    Originally Posted by Spirit_12 View Post
    One is for replacing vscript files, while this one allows you to create new vscript native functions which can be used in the scripts.
    Thanks
    __________________
    Mi.Cura | Modded Servers | L4D2
    https://steamcommunity.com/groups/micuramodzombie
    Mi.Cura is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 05:39.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode