![見出し画像](https://assets.st-note.com/production/uploads/images/109269569/rectangle_large_type_2_d0e3fd74dff82caafc09a15dbc31bea1.png?width=1200)
【ティラノビルダー】メッセージウィンドウと名前欄の位置を変更する方法
![](https://assets.st-note.com/production/uploads/images/109268060/picture_pc_87f5c77afabfce39f3cc902f2b3652d3.gif?width=1200)
ティラノビルダーでメッセージウィンドウと名前欄の位置を変更する方法について解説します。
画面の大きさは1280×720を想定しています。
①メッセージウィンドウと名前欄の位置の変更
![](https://assets.st-note.com/img/1687773464152-ZYfcKgUQZJ.png?width=1200)
メッセージウィンドウを表示させる前に、ティラノスクリプトコンポーネントを配置します。
![](https://assets.st-note.com/img/1687773470975-7qSJXlB7hy.png?width=1200)
下記のコードを貼り付けます。
[position width=920 height=211 top=451 left=180]
[position page=fore margint=45 marginl=10 marginr=20 marginb=10 vertical=false opacity="180" radius="0" color="0x000000" ]
[free name="chara_name_area" layer="message0"]
[ptext name="chara_name_area" layer="message0" color=0xFFFFFF size=26 x=190 y=461 bold="bold" edge="" shadow=""]
【コードの解説】
数値をお好みで変更してください。
■ メッセージウィンドウの大きさ・位置
[position width=920 height=211 top=451 left=180]
横幅 width=920
縦幅 height=211
X位置 left=180
Y位置 top=451
■ 文字の表示位置
[position page=fore margint=45 marginl=10 marginr=20 marginb=10 vertical=false opacity="180" radius="0" color="0x000000" ]
左 marginl=10
上 margint=45
右 marginr=20
下 marginb=10
■ 名前欄の位置
[ptext name="chara_name_area" layer="message0" color=0xFFFFFF size=26 x=190 y=461 bold="bold" edge="" shadow=""]
X位置 x=190
Y位置 y=461
これで、メッセージウィンドウと名前欄の位置を変更する手順は完了です。
以上で解説を終わります。おつかれさまでした。
【参考】初期設定の位置に戻す場合
![](https://assets.st-note.com/img/1687775551612-tR1RR4tMOG.png?width=1200)
[position width=1240 height=237 top=417 left=20 ]
[position page=fore margint=45 marginl=10 marginr=20 marginb=10 vertical=false opacity="180" radius="0" color="0x000000" ]
[free name="chara_name_area" layer="message0"]
[ptext name="chara_name_area" layer="message0" color=0xFFFFFF size=26 x=30 y=427 bold="bold" edge="" shadow=""]
【参考】初期設定の数値を調べる方法
![](https://assets.st-note.com/img/1687776396730-QZOYsB4hi8.png?width=1200)
画面左上のプロジェクト名をクリックします。
![](https://assets.st-note.com/img/1687776556717-taq8vBJYUn.png?width=1200)
フォルダが開かれるので、scenarioフォルダをクリックします。
![](https://assets.st-note.com/img/1687776640797-gVYuFmrc6C.png?width=1200)
systemフォルダをクリックします。
![](https://assets.st-note.com/img/1687776741403-N9lWgSdwzu.png?width=1200)
message_windowファイルをメモ帳で開きます。
![](https://assets.st-note.com/img/1687776921960-xr1qNxrFcG.png?width=1200)
初期設定の数値が記載されています。
※UIデザインツール・ゲームコンフィグのメッセージウィンドウの項目で数値を変更した場合、こちらの数値も上書きされます。
この記事が気に入ったらサポートをしてみませんか?