ツクールフォーラムのこちらのトピック
https://forum.tkool.jp/index.php?thread ... .90/page-2
で紹介されている下記スクリプトを使おうと思いました。
コード: 全て選択
/*:ja
* @param DRAW ID
* @desc SceneManager._sceneに関連付けるSprite名
* @default drawer
*/
(() => {
// 1.プラグインのファイル名をここに書く
const PLUGIN_NAME = "test";
// 2.この中に処理内容を書く
const draw = context => {
// context.fillText("Hello, World!", 48, 48);
}
const drawId = PluginManager.parameters(PLUGIN_NAME)["DRAW ID"];
const { update } = Game_Screen.prototype;
Game_Screen.prototype.update = function () {
update.apply(this);
main();
}
const [width, height] = [SceneManager._screenWidth, SceneManager._screenHeight];
const main = () => {
if (!SceneManager._scene[drawId]) {
SceneManager._scene[drawId] = new Sprite();
SceneManager._scene[drawId].bitmap = new Bitmap(width, height);
SceneManager._scene.addChild(SceneManager._scene[drawId]);
}
const { bitmap } = SceneManager._scene[drawId];
const { context } = bitmap;
bitmap.clear();
// context.textBaseline = 'top'; // テキストの基準位置を左上にする
draw(context);
}
})()
無事マップに図形を描写することはできたんですが、アニメーションの上に表示されてしまいます。
どこをどう変更すればアニメーションの下に図形を描写することができるのでしょうか?
ご回答お待ちしております。