Main Menu
  • Welcome to The RPG Maker Resource Kit.

Scripting Questions :O!!

Started by firerain, August 03, 2007, 01:07:16 AM

0 Members and 1 Guest are viewing this topic.

firerain

I'm a noob at scripting, so I was wondering what and how to make a small script where it shows a picture made in photoshop, the person presses enter and it closes, I tried doing it with events, but that failed. I also want to know how to make the script for when I hold a certain key(SHIFT) my character sprints not just walks.

Kokowam

#1
Sprinting, that can be done with events. You just need another spriteset. The picture thing, I think it can be done with events and loops (99% sure). Brb. Lemme test.

EDIT: Okay. I haven't tested but I think this will work. Here's what the event should look like:

@>Text: Show picture?
@>Choices: Yes, No
  :  When [Yes]
    @>Show picture blah blah blah...
    @>Loop
      @>Conditional Branch - Check if key whatever is pressed
        @>Break Loop
      :   Branch end
    :   Repeat Above
    @>Remove Picture #
  :   When [No]
    @>
Branch End
END!

firerain

I've tried that, the key thing doesn't work. Even if it did, the list doesn't have all the keys, and some of them are wrong, for example, Z ended up being F..or whatever it was.

Kokowam

That's because you set it in the controls when you press F1 when you start the game... C = Enter/Spacebar. B = ESC/X. Etc.

firerain

I still don't quite follow, how do I make it so when I press the Enter key, the picture dissapears?

Kokowam

Well, do conditional branches. The enter key in RMXP by default is actually the "C" button. So checking for C (which is really Enter)

firerain

I've tried everything you've suggested, it doesn't work.

modern algebra

Demo attached.

I did it a little differently, using Key Input Processing instead, but moo's way would also work, I just don't like using loops.