Raised This Month: $32 Target: $400
 8% 

[DoD:S] game_player_equip entity fix (0.1.1)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Prof. Orribilus
Member
Join Date: Jun 2013
Location: Italy
Plugin ID:
4920
Plugin Version:
0.1.1
Plugin Category:
Gameplay
Plugin Game:
Day of Defeat: Source
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Allow mappers to assign more than one ammo to pickable weapons placed in their map.
    Old 11-25-2015 , 20:47   [DoD:S] game_player_equip entity fix (0.1.1)
    Reply With Quote #1

    If you didn't know, "game_player_equip" is the name of a mechanism, implemented in some Source Engine based games, which allows mappers to set the outfit of players during gameplay. In Day of Defeat: Source, this can be used to place pickable weapons in the scenery; so, for example, a player can change their main weapon without changing class, and without waiting the drop of another player, or can pick a grenade not provided by his class. But in Day of Defeat: Source there are two issues about this mechanism:
    • These pickable weapons can't have more than one ammo.
    • If the player picks a weapon (except some grenades) which takes up a slot occupied by a weapons he owns, the picked weapon is spawned to the player position, falls over the ground then disappears. (mainly a visual issue, however)
    so, this plugin fixes this.



    Requirements:
    I tested this plugin on SourceMod 1.7.3 build 5275, but every build which works on the latest version of Day of Defeat: Source should be good.

    Notes for programmers and mappers:
    • This plugin needs SMlib during compile; i have attached the snapshot from its GitHub i used.
    • This plugin corrects what happens when the game_player_equip entity receive the Use input and the activator is the player. I tested it with a trigger_multiple linked to a game_player_equip, but even a func_button should work.
    • As you can imagine, the amount of ammo must be specified in the value field related to the weapon specified as key name. A single unit of ammo is a single round, not a single bullet (except for bazooka and grenades).
    • I attached a map for testing purposes.
    Maps designed for this plugin:



    Obviously, any feedback is well accepted.
    A thanks to the authors of SourceMod, the SMlib and SPEdit.
    Attached Files
    File Type: smx GPEentityfix4DoDS.smx (15.3 KB, 228 views)
    File Type: zip GPEentityfix4DoDS, source code.zip (75.2 KB, 233 views)
    File Type: zip dodstest_gameplayerequip map.zip (35.6 KB, 211 views)
    __________________


    Last edited by Prof. Orribilus; 04-16-2019 at 05:28.
    Prof. Orribilus is offline
    Prof. Orribilus
    Member
    Join Date: Jun 2013
    Location: Italy
    Old 12-12-2015 , 05:26   Version History
    Reply With Quote #2

    Version History:
    • 0.1.0
      • Initial release
    • 0.1.1
      • Now the plugin works as described (a single unit of ammo is a single round, not a single bullet)
      • Now weapons associated to the same slot can all be given to the player
    __________________


    Last edited by Prof. Orribilus; 12-12-2015 at 11:24.
    Prof. Orribilus 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 00:33.


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