回复:4楼其实我是想忽略间距问题的。因为用draw_sprite_part来绘制那么计算间距有点麻烦,还要用到碰撞盒。毕竟每个字符宽高不同。而且做成字体那么定位什么的更方便了点,不然左右对齐、居中计算的比较麻烦~ 5楼2011-01-23 16:59 回复 扫二维码下载贴吧客户端 下载贴吧APP看高清直播、视频! 贴吧页面意见反馈 违规贴...
您可以将它们分配给对象,或将它们赋值给代码创建的实例,它们也能响应实例中大部分精灵变量——可以缩放,旋转,着色和更改alpha值——所有这些都可以在游戏中操作。可以像使用其他任何精灵一样使用大部分sprite_*()函数来绘制它们,但draw_sprite_pos()和draw_sprite_part() 不适用。 但是,使用Spine的目的是创建具有多...
1、这是我调整过的:draw_sprite(spr_life_bar_foregro un d,0,x,120);draw_sprite_part(spr_life_bar,0,0,96*(1-life/maxlife),114,96*(life/maxlife),0,120+96 *(1-life/maxlife);我通常用:draw_sprite_ext();那个对对碰中的分数进度条和时间进度条都是这样画出来的。呵。GM版山寨弹性贪吃蛇...
draw_sprite_part(spr_life_bar,0,0,96*(1-life/maxlife),114,96*(life/maxlife),0,120+96*(1-life/maxlife)); 我通常用: draw_sprite_ext();那个对对碰中的分数进度条和时间进度条都是这样画出来的。呵。 GM版山寨弹性贪吃蛇教程 首先,创建两个精灵,并将其大小设定为:16*16。这里,我就用了两个...
and you don't necessarily want to do that all the time.Image_xscalewill flip the sprite, but it also flips the sprite mask, which can cause problems. Part of the reason we are usingdraw_sprite_ext();is that we are bypassing all of these built-in variables that can cause issues. Add...
I want to make something like this image (could not upload it here). Draw a line between two points, but not a "draw_line" line, instead a sprite, constantly repeating itself until reach the target. I've already tried draw_sprite_part but it didn't work... ...
draw_sprite_part(sprite,subimg,left,top,width,height,x,y) 在坐标(x,y)绘制指定范围内的子图像的子图区域 (-1 代表当前子图像)(从子图像内位置 left,top,width,height )。 draw_sprite_ext(sprite,subimg,x,y,xscale,yscale,rot,color,alpha) 代表所要绘制的精灵,subimg 代表要绘制的具体子图像,(x,...
sprite = sprEnemy_Hurt; break; } //reset frame to 0 if sprite changes if(lastSprite != sprite){ lastSprite = sprite; frame = 0; } 这里没什么好说的。我们所做的就是根据状态设置精灵,就像我们对玩家一样。 OK,敌人设置完成!放在房间里一两个敌人。下面到了比较难的部分了...检查hitbox / hur...
Since this is the score object, it'll have the spr_score_card sprite assigned to it. We want to change this to spr_highscore_card, which is just the same image but a little wider. Open the Draw event for this new object, which should already have some actions. We want to change wh...
I actually don't need to use draw_sprite_part, draw_sprite is good enough. Because GM autocrops out blank space and stores the origin, you can simply make a copy of sprite and cut out the same parts in each subimage to split it up into different sprites and use the same origin ...