Save-Point
RPG Developer Bakin: Grid Based Movement - Printable Version

+- Save-Point (https://www.save-point.org)
+-- Forum: Material Development (https://www.save-point.org/forum-8.html)
+--- Forum: Event Systems Database (https://www.save-point.org/forum-38.html)
+--- Thread: RPG Developer Bakin: Grid Based Movement (/thread-8624.html)



RPG Developer Bakin: Grid Based Movement - JayRay - 01-03-2023

Note: This event system is for RPG Developer Bakin. In order to add this event, copy to a simple .txt file, and then simply import the .txt file after saving your game on an event screen, and it will fill in the nodes automatically!



Grid Based Movement!

Originally created by MelonToucan
This Common Event system will allow you to forego the non-grid based movement for a simpler 8 direction grid based one. Adjust for different resolutions.


Code:
Guid    fc503ff2-f343-4b32-bafa-67a7e9faa4ce
イベント名    GridMovement
シート    Event Sheet
    グラフィック    00000000-0000-0000-0000-000000000000
    向き    -1
    向き固定    False
    物理    False
    衝突判定    True
    イベントと衝突    True
    移動速度    0
    移動頻度    0
    移動タイプ    NONE
    押せる    True
    スクリプト
        開始条件    PARALLEL
        高さ無視    False
        判定拡張    False
        コマンド    SWITCH
            変数    N:LockPlayer
            整数    0
        コマンド終了
        コマンド    COMMENT
            文字列    Stops all regular player movement from happening
        コマンド終了
        コマンド    HLVARIABLE
            整数    0
            ローカル変数    pressUP
            整数    12
            整数    0
            整数    0
        コマンド終了
        コマンド    HLVARIABLE
            整数    0
            ローカル変数    pressDOWN
            整数    12
            整数    1
            整数    0
        コマンド終了
        コマンド    HLVARIABLE
            整数    0
            ローカル変数    pressLEFT
            整数    12
            整数    2
            整数    0
        コマンド終了
        コマンド    HLVARIABLE
            整数    0
            ローカル変数    pressRIGHT
            整数    12
            整数    3
            整数    0
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing Down and Right at the same time
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressDOWN
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    0
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    45
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing Down and Left at the same time
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressDOWN
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    0
            整数    1
            整数    0
            整数    -45
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing Up and Right at the same time
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressUP
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    0
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    0
            整数    1
            整数    0
            整数    135
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing Up and Left at the same time
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressUP
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    -135
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing up, but not left or right
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressUP
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    180
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing down, but not left or right
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressDOWN
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    0
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing left, but not down or up
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressLEFT
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressDOWN
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressUP
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    -90
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    COMMENT
            文字列    Pressing right, but not down or up
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressRIGHT
            整数    1
            整数    0
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressUP
            整数    1
            整数    3
        コマンド終了
        コマンド    IFVARIABLE
            ローカル変数    pressDOWN
            整数    1
            整数    3
        コマンド終了
        コマンド    COMMENT
            文字列    Being held, pressed, let go, etc.
        コマンド終了
        コマンド    PLWALK
            整数    10
            小数    1
            整数    0
            整数    1
            整数    1
            整数    1
            整数    0
            整数    90
            整数    0
            整数    0
            整数    0
        コマンド終了
        コマンド    PLSNAP
        コマンド終了
        コマンド    COMMENT
            文字列    If you want event to move this way you would just enter this into the events motions.
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
        コマンド    ELSE
        コマンド終了
        コマンド    ENDIF
        コマンド終了
    スクリプト終了
シート終了



RE: RPG Developer Bakin: Grid Based Movement - kyonides - 01-03-2023

Can we get an English translation please? Happy with a sweat

There's a lot of stuff in Japanese that I'd prefer to be able to read in English. Laughing


RE: RPG Developer Bakin: Grid Based Movement - JayRay - 01-04-2023

It's not for you to read, it's for you to copy to a text file.

Once you create an event, and then import that text file into it, you can read it completely. 
One of the benefits of Bakin is that events can be copied from project to project in this way.

However, the import/export feature is always going to partially be in Japanese.
But depending on what translation you have, the panels will show up for you in engine as English.

[Image: oaGrcR7.png].