Announcement

Collapse

Forum Rules

  • No flaming or derogatory remarks, directly or through insinuation.
  • No discussion, sharing or referencing illegal software such as hacks, keygen, cracks and pirated software.
  • No offensive contents, including but not limited to, racism, gore or pornography.
  • No excessive spam/meme, i.e. copious one liners in a short period of time, typing with all caps or posting meme responses (text/image).
  • No trolling, including but not limited to, flame incitation, user provocation or false information distribution.
  • No link spamming or signature advertisements for content not specific to Dota 2.
  • No Dota 2 key requests, sell, trade etc.
  • You may not create multiple accounts for any purpose, including ban evasion, unless expressly permitted by a moderator.

  • Please search before posting. One thread per issue. Do not create another thread if there is an existing one already.
  • Before posting anything, make sure you check out all sticky threads (e.g., this). Do not create new threads about closed ones.
  • It is extremely important that you post in correct forum section.

  • Balance discussion only in Misc.
  • All art related (such as hero model) feedbacks go to Art Feedback Forum.
  • All matchmaking feedback should go here: Matchmaking Feedback
  • All report/low priority issues should go here: Commend/Report/Ban Feedback
  • No specific workshop item feedback. These should go to workshop page of that item.
  • When posting in non-bugs section (such as this), use [Bugs], [Discussion] or [Suggestion] prefix in your thread name.



In case you object some action by a moderator, please contact him directly through PM and explain your concerns politely. If you are still unable to resolve the issue, contact an administrator. Do not drag these issues in public.



All rules are meant to augment common sense, please use them when not conflicted with aforementioned policies.
See more
See less

[Suggestion] Add a convar for to know what mod is being played

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [Suggestion] Add a convar for to know what mod is being played

    It would be great if there was a convar we could grab to know what mod is being played, via Lua.

    Ideally, I would want to know the workshopID, but even just the mod name would be nice.

    If the convar is set, I could grab it via Lua using a method like cvar_getf() which unfortunately only returns a float.

    Having this functionality would allow me to make mod specific logic, that would not activate if someone copy pasted all of my Lua. The idea being that they would need to actually read and modify the Lua to maliciously muck-up any external dependencies, or to simplify the code between two versions of the same mod (i.e. the developer only Beta version, and the live workshop version).


  • #2
    If we get a convar for the workshopID, it would also be nice to get one that reports the mod version. It would assist stat tracking, as we could attribute results directly to their mod version.

    Comment


    • #3
      I can see this being useful to have logic that only shows when on a dev version of the mod, like the side bar in hero_demo to test things

      Comment


      • #4
        Pretty sure you can inject stuff in vpk archive so your defense would be useless. They would get the map id, and send whatever stuff they want to your server.
        Known Tooltips and UI information Issues List
        Unreleased heroes data:

        Hero Balance Compilation 6.48 onwards
        Items and Other Balance compilation 6.48 onwards
        Dota 1 6.81c Test Map

        Comment


        • #5
          Originally posted by igo95862 View Post
          Pretty sure you can inject stuff in vpk archive so your defense would be useless. They would get the map id, and send whatever stuff they want to your server.
          The defense is mainly to prevent stuff like lod x5 which was literally just a copy+paste of Legends of dota with the units_custom / abilities_custom of PowerMultiplier x5, and it included all the statcollection stuff of lod which was messing with stats

          Comment


          • #6
            Exactly, but doing dev specific logic would be a nice bonus too.

            Comment


            • #7
              Originally posted by jimmydorry View Post
              Exactly, but doing dev specific logic would be a nice bonus too.
              You can do dev specific logic by using "developer 1" console variable.

              ConVars:GetBool("developer")
              Known Tooltips and UI information Issues List
              Unreleased heroes data:

              Hero Balance Compilation 6.48 onwards
              Items and Other Balance compilation 6.48 onwards
              Dota 1 6.81c Test Map

              Comment


              • #8
                @igo95862:

                You are not contributing to this very specific request. A convar that has the workshopID and if possible, another convar that has the patchNumber. This is specific for stat recording, and we know and understand the exact limitations of relying and using it in mod logic.

                Previous issues we have had would be completely avoidable if we had the workshopID field, and it would make quite a few things much simpler for us. The patchNumber would enhance the kind of statistics we collect, and better serve to segment the data used for reports.

                Comment


                • #9
                  Seems useful.

                  Comment


                  • #10
                    Having a convar or function to return the workshopID present (0 for tools mode?) would allow game developers to have logic that only fires when its being played in production (ie, statcollection).

                    but can also allow developers to have special debug shown when it is the test workshopID (ie, a public workshopID and a developer / test workshopID) to have extra debug either in Panorama or in console, without fear of accidentaly leaving it in production (preferably nothing game breaking to get around @igo95862's problems with it, use "developer" convar for that)

                    Comment


                    • #11
                      bump

                      convar or something else, but we would greatly benefit from this
                      ModDota | My GitHub Profile | My Project's Page

                      Comment


                      • #12
                        This is still something that would be really useful to us using the stat-collection library.

                        Comment

                        Working...
                        X