Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. The Criminal Enterprises
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Support

    3. Suggestions

*DO NOT* SHARE MEDIA OR LINKS TO LEAKED COPYRIGHTED MATERIAL. Discussion is allowed.

How to edit Controls for .net Scripts Help


hackoncrack
 Share

Recommended Posts

Hi I'd like to change a button is some .net scripts. It's easy when the script is in .cs format but when it is in DLL i dont know what to do. Not always the ini files let u change the keys and when they do i dont know the virtual key code for a button on the 360 controller.

 

Instead of using action on theyboard for this mod id like to use action on the controller...thanks for your help if you know how! biggrin.gif

Link to comment
Share on other sites

Well, I think it's against the rules of this forum to explain ways of manipulating dlls to view what is inside them so you're out of luck there. But if your scripts have ini files and the key codes are numbers. You could always try getting the ascii value of whichever key you want. The ways of doing this vary depending on what programming language you use. If you're experienced in any kind of programming you should know how to do this easily smile.gif

 

Of course i'm sure you could always just look online for the ascii key values aswell.

 

EDIT: An xbox 360 controller uses analog and as far as it's buttons go i've never found a way to have a script use them confused.gif

Edited by Tsproggy
Link to comment
Share on other sites

Thank you for your reply. Well for scripts that are in .cs format i am able to use the 360 controller by changing the function that determines the key being used like this:

 

isKeyPressed(Settings.GetValueKey("Key", Keys.G)) >> Game.isGameKeyPressed(GTA.GameKey.Sprint)

 

Would this help me maybe regarding using the ASCI value? I have no experience as a coder but familiar with structuring formulas from Excel si im able to figure out edits like the one above but the virtual key code has me stumped.

 

So if an ini file asks me for the virtual key code i want to use i might be able to assign a 360 controller button if I know the ASCI value of the controller buttons??

 

Thank you for your reply!

Link to comment
Share on other sites

Is the following useful to me?

 

Flash ASCII Code Values

 

With the exception of the right analog stick, you can listen for controller input in Flash as well. See this post (http://forums.epicgames.com/showthread.php?p=27828371#post27828371) for details on how to listen for keyboard/controller input in Flash. The ASCII codes to listen for are:

 

Left Analog Stick & D-Pad (Left): 37

Left Analog Stick & D-Pad (Up): 38

Left Analog Stick & D-Pad (Right): 39

Left Analog Stick & D-Pad (Down): 40

 

A: 96

B: 97

X: 98

Y: 99

 

Left Shoulder: 100

Left Trigger: 101

 

Left Analog Stick (Pressed): 102

 

Right Shoulder: 103

Right Trigger: 104

 

Right Analog Stick (Pressed): 105

 

Start: 106

Back: 107

 

It says these are for Flash, im not sure if that means i could apply it to gta 4 mods that ask for virtual key codes in the ini? If so then i dont need to mess with decompiling and re compiling the .dll because....welll. id prolly mess that up pretty good...lol

Edited by hackoncrack
Link to comment
Share on other sites

I gave up...im using joy2key and its so much easier, would have prefered to code evrything in though confused.gif

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.