设为首页收藏本站同能贴吧 切换语言 繁体中文
开启辅助访问 切换到窄版
扫描二维码关注官方公众号
返回列表
+ 发新帖
查看: 106|回复: 0

[制作教程] How to Choose a Main Actor's Appearance

[复制链接]
累计送礼:
0 个
累计收礼:
1 个
  • TA的每日心情
    开心
    前天 04:10
  • 签到天数: 209 天

    连续签到: 2 天

    [LV.7]常住居民III

    4446

    主题

    864

    回帖

    2万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    VIP
    7
    卡币
    22899
    OK点
    16
    推广点
    0
    同能卷
    50
    积分
    28239

    灌水之王

    发表于 4 天前 | 显示全部楼层 |阅读模式
    Tutorial topic: Selecting an appearance for your main actor from several choices

    Brief description: You will be able to examine several sprites and choose one for your main actor's appearance. The main actor's images will be changed in the system.

    Requirements: Nothing special, just RMMV

    I used events to create a game where you can select your main actor's appearance. This allows you to have multiple choices based on gender, hair color, class selection, or whatever. Let's say you want to have blond, brown, black, and green hair choices, and you want a different set of clothes based on whether the actor is a warrior, martial artist, mage, or cleric. Four choices times four choices means 16 sets of faces, sprites, and battlers. In my case, I just wanted diverse choices, since my main actor is basically an avatar for the player.

    I start off the game with the main character's appearance set to a default. In my case, it's an NPC who guides the actor out once the selection is done. You could have it be a dog or something instead, recognizing its owner out of a line. You could even make the actor look like a glowing arrow, and set up the map to look like a menu, and have them walk up and down a line between impassable tiles. I also want to be able to cancel a choice or change my mind, and I don't want the party to leave until a selection is made. Here's how this looks:

    Demo


    https://www.youtube.com/embed/ybkeEMVoK68

    Here's what you need to set this up:

    1. You need a variable to control the events. I chose variable number 7 and called it Control, and I will use it to control events where you make a selection.
    2. You need some switches, one for every possible choice. I suggest setting aside a block of 20 switches for event controls. If you just started a project, I suggest setting aside switches 1-20 for this purpose, and not using them for anything permanent.
    3. I suggest for simplicity's sake, putting your main actor in the 1st actor slot. Give them a default name and set their appearance to whatever your selector sprite is going to be. In my example, it's a friendly sorceress who acts as a guide.
    4. You need some dummy actors. Create an actor for every appearance choice. Assign each one a number, in order, that you will use for your control variable. I suggest strongly that when you are setting this up and selecting or creating the images for each actor, you name them numerically, and then change all their names in the DB to your default main actor name ("Our Hero") once your map is working.
    5. Create your map where the selection is made.
    6. Create a special Common Event, Reset Party. This removes all the dummy actors, and resets the switch corresponding to each dummy actor EXCEPT the one matching the current value of Control.

    On your map, each selectable appearance is an event, corresponding to one of your dummy actors. When the player activates the event, ask them to confirm. If they confirm, you set the Control variable to match the actor's place in line, activate the Common Event (Reset Party), and turn on self-switch A. You add the chosen dummy actor to the party. Now, on the second page, if Switch A is active, you have a picture of some kind they can click on to reset Control to 0 and remove the dummy actor, resetting the choice. We're back to your original state. On the third page, there is an Autorun event. It checks if the switch has been turned On by the Common Event. If it has, it means a selection is made, so we're going to clear the self-switch, and of course, reset the switch to prevent the Autorun from repeating. Now this event is back to its original state, with the self-switch off. Note that because of how our Common Event runs, it won't have turned on the switch corresponding to this dummy actor, so their Switch A remains active.

    If you were to use an arrow or something, instead of adding each dummy actor, you could instead have Switch A cause the event on page 2 to start stepping, or active a glowing event behind them, or whatever. In that case you don't need the Common Event to remove anybody, just operate the switches.

    The exit to the map is an event as well. It's set as the same level as the party, and if you try to leave, it informs you your party isn't ready to go. Page 2, however, will trigger if Control is equal or greater than 1, meaning a selection was made and not cleared. In that case, a series of conditional branches compares the Control variable to each value, and if it matches, changes the main actor's appearance in the system to match the corresponding dummy character. There's no reason to nest anything, as the variable can only have one value. If you wanted to get fancy, you could probably script this part. Then you run the Common Event again. This removes the dummy actor and prevents your main actor from appearing on the next screen with an evil clone in tow. Then I clear all the switches I used, for housekeeping. Since I'm using those switches for combinations of events, I'll always want to make sure I know their values before I use them, buy why risk leaving them on?

    And that's it.

    One variation is that all your dummy actors have a different class (in case someone checks the menu), and when you exit, in addition to setting the main actor's appearance, you change their class (and teach them any pertinent Skills).

    Another variation is that you can use a similar system for party building, like the original Final Fantasy. Your 1st actor will actually be your dummy, and all the possible selections will be your actual party. You can remove the dummy actor when you start building the party, and add it back if they get rid of their last choice. Instead of using a self-switch and having a Common Event clear all the switches, you can just just use the switches, with On meaning the actor is chosen. Before the actor is added, check party size. If the party is too big, the player will have to put somebody back.


    本贴来自国际rpgmaker官方论坛作者:pawsplay处,因国际论坛即将永久关站,为了存档多年珍贵资料,署名转载到本论坛存档,由于官方帖子为英文原帖,需要中文翻译请点击论坛顶部切换语言为中文就可以将帖子翻译成中文浏览,方便大家随时查看,原文地址:https://forums.rpgmakerweb.com/threads/how-to-choose-a-main-actors-appearance.143837/
    天天去同能,天天有童年!
    回复 送礼论坛版权

    使用道具 举报

    文明发言,和谐互动
    文明发言,和谐互动
    高级模式
    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    简体中文
    繁體中文
    English(英语)
    日本語(日语)
    Deutsch(德语)
    Русский язык(俄语)
    بالعربية(阿拉伯语)
    Türkçe(土耳其语)
    Português(葡萄牙语)
    ภาษาไทย(泰国语)
    한어(朝鲜语/韩语)
    Français(法语)
    关闭

    幸运抽奖

    社区每日抽奖来袭,快来试试你是欧皇还是非酋~

    立即查看

    聊天机器人
    Loading...

    QQ|Archiver|手机版|小黑屋|同能RPG制作大师 ( 沪ICP备12027754号-3 )

    GMT+8, 2026-7-14 14:29 , Processed in 0.067822 second(s), 55 queries .

    Powered by Discuz! X3.4

    Copyright © 2001-2020, Tencent Cloud.

    快速回复 返回顶部 返回列表