Charas-Project

  • Home
  • Help
  • Search
  • Calendar
  • Login
  • Register
*
Please login or register.

Login with username, password and session length
 

News:

New forum theme up and running!



  • Charas-Project »
  • Game Creation »
  • Requests »
  • RPG Maker Programming »
  • Key Implementation
« previous next »
  • Print
Pages: [1]

Author Topic: Key Implementation  (Read 2536 times)

Offline Reishadowen

  • Member
  • Initiate
  • *
  • Posts: 7
Key Implementation
« on: April 24, 2006, 04:48:07 PM »
Since I can't find anything here, or at GW, and the search button here keeps crashing me, How do you change key configuration, or add additional keys to do extra actions? My RPG will require extra buttons, and the cancel/accept are'nt enough. Any help?
Logged

Offline WarxePB

  • Action Sue
  • Royal
  • *
  • Posts: 3,601
  • What killed the dinosaurs?
    • The Gigaverse
(No subject)
« Reply #1 on: April 24, 2006, 08:25:08 PM »
Switch from RM2K to RM2K3. 2K3 has more key input commands, hence more assignable actions.

And before you ask: read this.
Logged
Blog: The Gigaverse
Twitter: Initial Chaos

Offline Bluhman

  • Global Moderator
  • Royal
  • *
  • Posts: 4,977
(No subject)
« Reply #2 on: April 24, 2006, 08:29:39 PM »
Quote
Originally posted by Warxe_PhoenixBlade
And before you ask: read this.


What the heck did that do?
Logged

Offline WarxePB

  • Action Sue
  • Royal
  • *
  • Posts: 3,601
  • What killed the dinosaurs?
    • The Gigaverse
(No subject)
« Reply #3 on: April 24, 2006, 11:55:48 PM »
Quote
Bluhman
What the heck did that do?


Proved that i'm an idiot. >_<

Link fixed
Logged
Blog: The Gigaverse
Twitter: Initial Chaos

Offline Darkfox

  • These spectacles do nothing
  • Staff
  • Over 9000!
  • *
  • Posts: 10,215
    • Chaos Realm - Home of the God Beasts
(No subject)
« Reply #4 on: April 24, 2006, 11:57:06 PM »
Warxe an idiot? Since when? O_o My speech has been downsized to single words.
Logged



Offline Reishadowen

  • Member
  • Initiate
  • *
  • Posts: 7
(No subject)
« Reply #5 on: April 25, 2006, 01:00:51 AM »
Quote
Originally posted by Warxe_PhoenixBlade
Switch from RM2K to RM2K3. 2K3 has more key input commands, hence more assignable actions.

And before you ask: read this.
Ok, first off, I'm already using 2003 version. Second, I don't know about any of that illegal translation of posting stuff, I just want to know how to make customizable keys, and add keys for more in-game commands and such. I've looked over the 2003 version, and either I don't know what I'm looking for, or it does'nt exist. Can anyone help me?
Logged

Offline WarxePB

  • Action Sue
  • Royal
  • *
  • Posts: 3,601
  • What killed the dinosaurs?
    • The Gigaverse
(No subject)
« Reply #6 on: April 25, 2006, 11:47:36 AM »
Nevermind about that link, then.

In order to create new keys, you'll have to use a Key Input Process command (might also be called Password).  Open up the Database, and go to Common Events. Create a new event, name it what you like, and set it to Parallel Process (putting a switch on is optional). In the code, create a Key Input/Password (it's on page 3 of the Event Commands list), with the keys that you want to use checked. Make sure you set the variable to something you won't use later.
After that, create a Conditional Branch/Fork Condition, checking if the variable is equal to a certain number. For example, if you want Shift to trigger something in-game, use the branch to check if the variable is 7. Inside the branch, insert the code that you want to trigger.

If more clarification is needed, please post again.
Logged
Blog: The Gigaverse
Twitter: Initial Chaos

Offline Reishadowen

  • Member
  • Initiate
  • *
  • Posts: 7
(No subject)
« Reply #7 on: May 02, 2006, 01:12:02 PM »
Quote
Originally posted by Warxe_PhoenixBlade
Nevermind about that link, then.

In order to create new keys, you'll have to use a Key Input Process command (might also be called Password).  Open up the Database, and go to Common Events. Create a new event, name it what you like, and set it to Parallel Process (putting a switch on is optional). In the code, create a Key Input/Password (it's on page 3 of the Event Commands list), with the keys that you want to use checked. Make sure you set the variable to something you won't use later.
After that, create a Conditional Branch/Fork Condition, checking if the variable is equal to a certain number. For example, if you want Shift to trigger something in-game, use the branch to check if the variable is 7. Inside the branch, insert the code that you want to trigger.

If more clarification is needed, please post again.
Ok, now, does the variable instantly return to zero once the key is'nt depressed any more, or will it stay at 7 even after I let go of the shift key? If so, how do I get it to reset? Is there a simple solution or will I have to program like five different events for it or something? Also, thanks for the help.
Logged

Offline Sephiroth rocks

  • Acolyte
  • *
  • Posts: 479
(No subject)
« Reply #8 on: May 02, 2006, 01:26:16 PM »
You'll have to reinitialize the variable yourself. Also keep in mind that if you want the user to tap a key you'll have to check if the prevous keypress was the same to prevent that the user can simply hold down the key.
Logged

  • Print
Pages: [1]
« previous next »
  • Charas-Project »
  • Game Creation »
  • Requests »
  • RPG Maker Programming »
  • Key Implementation
 

  • SMF 2.0.10 | SMF © 2015, Simple Machines
  • XHTML
  • 2O11
  • RSS
  • WAP2
  • Simple Machines Forum