B
bruhmoment.wav
Guest
This is the code I used to assign the position of the object:
The object somehow seems to be moving at the same speed the player is moving. But I have no idea how that connection came to be.
GML:
if oPlayer.holdingItem = 1 {
image_alpha = 100;
if oPlayer.heldItem = "oSword" {
sprite_index = sSword;
}
}
if oPlayer.holdingItem = 0 {
image_alpha = 0;
}
vx = camera_get_view_x(view_camera[0])+16
vy = camera_get_view_y(view_camera[0])+camera_get_view_height(view_camera[0])-16
x = vx
y = vy
image_xscale = 2; image_yscale = 2;
Attachments
-
335.4 KB Views: 9