Scripting Events and Triggers.

Post » Mon Jun 18, 2012 2:46 am

It seems when creating events to trigger scripts, Bethesda forgot one major event.
OnKeyPress()
Ie.. when the user presses a certain key.
I am trying to do one of two things to make up for this lack.

Either find a way to detect keyboard events and respond to them.
Or set up a timer to poll every so often to check for an outside event in a program.
The reason was wondering this is because I have a program that runs outside skyrim to trigger events inside the game. (See my signature)
Integrating the outside program into Skyrim directly is pretty much a near impossible task as it is a voice recognition engine.

Essentially I need some way to tell Skyrim, "Hey the user shouter, and also, here's the word(s) he shouted."

Right now I do this by using script dragon and c++ to read the contents of hidden window.

Short Version
Any input on how to do a KeyBoardEvent or a TimedPoll using papyrus.


(Sadly, I always seem to ask questions that either are incredibly stupid or no one knows how to answer.)
User avatar
Haley Cooper
 
Posts: 3490
Joined: Wed Jun 14, 2006 11:30 am

Post » Mon Jun 18, 2012 2:36 am

Yes, I have not seen any keypress interrupts or mousedown events. We'll probably require SKSE to brew up some magic for it. Also was hoping for a keyboard buffer, but one can dream.

Modders have always come up with ingenious ways to do what they need and I have no doubt that we'll be able to overcome it.
User avatar
DarkGypsy
 
Posts: 3309
Joined: Tue Jan 23, 2007 11:32 am

Post » Mon Jun 18, 2012 6:01 am

I suppose for the time being I just have to keep relying on Script Dragon.
User avatar
Dan Scott
 
Posts: 3373
Joined: Sun Nov 11, 2007 3:45 am


Return to V - Skyrim