This page is out of date

You've reached a page on the Ren'Py wiki. Due to massive spam, the wiki hasn't been updated in over 5 years, and much of the information here is very out of date. We've kept it because some of it is of historic interest, but all the information relevant to modern versions of Ren'Py has been moved elsewhere.

Some places to look are:

Please do not create new links to this page.


Hangul (Korean Alphabet) Input Class

You can't get hangul by (6.12.1), so if you want to put and use hangul character in your Ren'py game, you can use this code.

Before using it with your game, notice that

a) It implements Dubeolsik keyboard,
b) and it can't get alphabet characters.

How To Use

1. Download this rpy file and put it in your project\game directory.

2. And then you will be able to use this function.

Return two values. First one is the word inputted by user, and the other is 1 or 0, indicating if the last word has final consonant or not(So one can use it to change postpositional particle depending on the inputted text).

prompt - A prompt that is used to ask the user for the text.

default - A default for the text that this input can return.

legnth - A limit to amount of text that this function will return.

allow - A string containing characters that are allowed to be typed into this input. (By default, allow all characters.)

exclude - A string containing characters that are disallowed from being typed into this input. (By default, "{}".)

Styles

The following styles are to customize hangul inputter's appearance.

style.input

The style applied to inputted text.

Example

init:
    $ style.input.color = '#f00'
    transform a:
        alpha 0
        block:
            linear 1.0 alpha 1
            linear 1.0 alpha 0
            repeat
            
    screen hinput:
        add HangulInput('이름을 적어줘!') align (.5, .5) at a

label start:
    #python:
        #ui.add(HangulInput(length=5))
        #name, final=ui.interact()
        
    call screen hinput
    $ name, final = _return
    
    '이름: %(name)s\n받침유무: %(final)s'