<aside> <img src="/icons/shoe_gray.svg" alt="/icons/shoe_gray.svg" width="40px" />
ステップ
image_angle += 30; // 1フレームに30度回転
</aside>
<aside> <img src="/icons/light-bulb_gray.svg" alt="/icons/light-bulb_gray.svg" width="40px" />
作成
// タイマーの初期化
alarm[0] = random_range(10,60); // 10tick-60tickのランダムで移動開始
</aside>
<aside> <img src="/icons/alarm_gray.svg" alt="/icons/alarm_gray.svg" width="40px" />
アラーム0
var target=Object1; //移動先オブジェクト
var spd=5; //移動速度
// targetの方向を計算
var target_x = target.x;
var target_y = target.y;
//位置(x,y)から位置(x,y)に向かってspdの速度で移動
motion_set( point_direction(x, y, target_x, target_y), spd);
alarm[0] = random_range(10,60); // 10tick-60tickのランダムで移動開始
</aside>
<aside> <img src="/icons/shoe_gray.svg" alt="/icons/shoe_gray.svg" width="40px" />
ステップ
var stickX;
var stickY;
move_speed = 8;//移動速度
var ground=obj_ground;//判定対象
stickX = gamepad_is_connected(0) ? gamepad_axis_value(0, gp_axislh) : 0;
stickY = gamepad_is_connected(0) ? gamepad_axis_value(0, gp_axislv) : 0;
move_and_collide(stickX*8, stickY*8, ground,4,0,0,-1,-1);
</aside>