Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
Then, in the end step event, type in the following code:
image_angle = direction;
Changing the image_angle only changes the way the sprite faces, not the direction the object will move.
That worked with all my other problems but the event: Key press UP: Speed=4
doesn't work still :S But what you said fixed my firing lazer problem :D
[ Speed=4 ]
to work. All the rotation is working great and all based on the direction of the object not the sprite. but I cant get the object to move in the direction its facing.
If you are using I believe, could be wrong, that "speed" won't work and you'll need to use the physics "impulse" or "force" or to push / propel your ship.
Capitals and lower cases matter.
I'm guessing I'm not using physics as I don't know how to turn it on. You see it works with the ship's bullet it fires, I set its direction up when its created and then set its speed in the end step and it works fine, but not the ship itself.
I'm currently using the drag and drop action of Key Pressed [ UP ] - to activate the speed change
var left_move = (keyboard_check (vk_left) or keyboard_check (ord("A")))
var up_move = (keyboard_check (vk_up) or keyboard_check (ord("W")))
var down_move = (keyboard_check (vk_down) or keyboard_check (ord("S")))
if right_move {
phy_position_x += 5
sprite_index = right_move_anim
}
if up_move {
phy_position_y -= 5
sprite_index = jump
}
if left_move {
phy_position_x -= 5
sprite_index = left_move_anim
}
if down_move {
phy_position_y +=5
sprite_index = sit
}
if (!right_move and !left_move and !up_move and !down_move){
sprite_index = Sprite5
}
вставь нужные названия спрайтов и всё будет хорошо работать, прописывать нужно в скрипте Step (Rus)