空项目中的示例
1 创建一个精灵
示例:
spr_player
2 创建两个对象
示例:
obj_player // assign them the sprite that you created
obj_reflection
obj_player 上的 3 个
事件步骤
/// @description maker event step
// character movement
friction = 0.1;
if (keyboard_check (vk_right))
{
direction = 0;
speed = 4;
}
if (keyboard_check (vk_left))
{
direction = 180;
speed = 4;
}
if (keyboard_check (vk_up))
{
direction = 90;
speed = 4;
}
if (keyboard_check (vk_down))
{
direction = 270;
speed = 4;
}
obj_reflection 上的 4 个
活动抽奖
/// @description maker draw event
// redraw the object (the same sprite, same position x, same position and more the size of the object, same width, we invert the scale in half, same angle, same color mix, transparency in half)
draw_sprite_ext (spr_player,0,obj_player.x,obj_player.y + 100,image_xscale,-0.5,image_angle,image_blend, 0.5);
5 我们把两个物体都放在房间里,瞧我们有一个反射
6个实验改变数值看看结果
7对于水的效果,我们将物体放置在不同的层中,将反射物体放在下面,水的纹理在中间层
8 顺便说一句,我会说西班牙语,如果是,请在 https://es.stackoverflow.com/ 输入您的问题
如果您喜欢这个答案,请给我加 1,非常感谢。忙碌小丑 +51912423012