Cygnus Opublikowano 2 Września 2014 Opublikowano 2 Września 2014 Cześć wszystkim. Mam następujący problem,kiedy chcę przejść do następnej planszy: ################################################################################ ############ FATAL ERROR in action number 1 of Create Event for object obj_player: Pop :: Execution Error - Variable set failed phy_fixed_rotation - read only variable? at gml_Object_obj_player_CreateEvent_1 (line 6) - move_speed = 200; ####################################################################
kriso99 Opublikowano 2 Września 2014 Opublikowano 2 Września 2014 błąd jest w create objektu obj_player dotyczy zmiennej move_speed w link nr 6 nic wiecej sie nie dowiemy... no chyba ze wstawisz kod z obj_player...
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 Dziwne to,że mam 3 pokoje i te trzy pokoje działają,a ten nie działa:/ O to kod obj_player CREATE GML [/gml] start_x = x; start_y = y; phy_fixed_rotation = true; move_speed = 200; max_xspeed = 2; jumping = false; jump_force = -95; [gml]
Administratorzy gnysek Opublikowano 3 Września 2014 Administratorzy Opublikowano 3 Września 2014 I włączyłeś w obiekcie?
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 Dzięki chłopaki nie włączyłem fizyki w roomie. Ale teraz jest taki problem,ok przechodzę do tego pokoju,ale aimacja jest tam straszna..wszystko drastycznie wolno idzie:/ jak ruszam bohaterem,to chwile potrwa za nim zrobi krok. Kurcze co jest nie tak,Reszta pokojów dobrze działa.
Threef Opublikowano 3 Września 2014 Opublikowano 3 Września 2014 Może po prostu masz inny room_speed. Albo masz coś tak nawalone że aż spadają Ci FPS.
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 Prawdopodobnie tak,ale gdzie to ustawić sprawdzić? żeby to normalnie chodziło jak pozostałe pokoje?
kriso99 Opublikowano 3 Września 2014 Opublikowano 3 Września 2014 w draw gui GML draw_text(0,0,"Fps:"+string(fps)+"/"+string(room_speed))
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 Dzięki wklepałem ten kod w obj_player draw gui,ale nadal wolno mi działa..a reszta pokoi działa normalnie,kurcze:/ ręcę mi opadają:/
Piotrek1910 Opublikowano 3 Września 2014 Opublikowano 3 Września 2014 Może w step masz instance_create(*,*,*); który bez końca tworzy cały czas nowy obiekt.
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 We wszystkich pokojach,mam średnio ponad 50klatek na 60,a w tym ostatnim pokoju mam 2-4 klatki:/ kurcze,co jest nie tak:/ ten kod wklepałem,no to mam na górze informacje o ilości klatek.
Sutikku Opublikowano 3 Września 2014 Opublikowano 3 Września 2014 No i ta informacja jest niezmienna ? Cały czas jest stała liczba (np. 30), czy chaotycznie się zmienia 15, 28, 3, 14, 13, 12, 7 ?
Amaterasu Opublikowano 3 Września 2014 Opublikowano 3 Września 2014 Jeśli to jedyny room, w którym masz włączony silnik fizyczny, to może być wina starego sprzętu.
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 No chaotycznie się zmienia to fakt..klatki... Sprzęt mam bardzo dobry,więc to odpada. o to kod obj_player STEP GML [/gml] phy_speed_x = max(min(phy_speed_x, max_xspeed) , -max_xspeed); if(phy_speed_x > 0.1 || phy_speed_x < -0.1) { sprite_index = spr_Player_Running; } else{ sprite_index = sprPlayer; } if (phy_speed_y > 1.2) { sprite_index = spr_Player_Falling; } image_speed = phy_speed_x / 10; background_x[0] = -phy_position_x / 5; background_x[0] = -phy_position_y / 5; background_x[1] = -phy_position_x / 5; background_x[1] = -phy_position_y / 5;[gml] CREATE GML [/gml] start_x = x; start_y = y; phy_fixed_rotation = true; move_speed = 200; max_xspeed = 2; jumping = false; jump_force = -95; Tu niżej wszystko z obj_playera [gml] Information about object: obj_player Sprite: sprPlayer Solid: false Visible: true Depth: 0 Persistent: false Parent: Mask: spr_wall Physics Start Awake: true Is Kinematic: false Is Sensor: false Density: 1 Restitution: 0,1 Group: 0 Linear Damping: 1 Angular Damping: 0,1 Friction: 0,1 Shape: Box Points: (3,25, 0) (30, 0) (30, 30) (3,25, 30) Create Event: execute code: start_x = x; start_y = y; phy_fixed_rotation = true; move_speed = 200; max_xspeed = 2; jumping = false; jump_force = -95; set the health to 100 Alarm Event for alarm 0: execute code: ///make this happen Step Event: execute code: phy_speed_x = max(min(phy_speed_x, max_xspeed) , -max_xspeed); if(phy_speed_x > 0.1 || phy_speed_x < -0.1) { sprite_index = spr_Player_Running; } else{ sprite_index = sprPlayer; } if (phy_speed_y > 1.2) { sprite_index = spr_Player_Falling; } image_speed = phy_speed_x / 10; background_x[0] = -phy_position_x / 5; background_x[0] = -phy_position_y / 5; background_x[1] = -phy_position_x / 5; background_x[1] = -phy_position_y / 5; if health is smaller than 1 jump to the start position restart the game Collision Event with object obj_Collision: execute code: ///make this happen Collision Event with object obj_kamien: execute code: ///make this happen Collision Event with object obj_centralnyPrawy: execute code: ///make this happen Collision Event with object obj_kolce: set the health relative to -5 Collision Event with object obj_enemy: set the health relative to -1 Collision Event with object obj_skosikowy: execute code: ///make this happen Collision Event with object obj_platformaTrawaM: execute code: ///make this happen Collision Event with object obj_skosikP: execute code: ///make this happen Collision Event with object obj_woda: set the health relative to -5 Collision Event with object obj1: execute code: ///make this happen Collision Event with object obj2: execute code: ///make this happen Collision Event with object obj3: execute code: ///make this happen Collision Event with object obj4: execute code: ///make this happen Collision Event with object obj5: execute code: ///make this happen Collision Event with object obj6: execute code: ///make this happen Collision Event with object obj7: execute code: ///make this happen Collision Event with object obj8: execute code: ///make this happen Collision Event with object obj9: execute code: ///make this happen Collision Event with object obj10: execute code: ///make this happen Collision Event with object obj11: execute code: ///make this happen Collision Event with object obj12: execute code: ///make this happen Collision Event with object obj13: execute code: ///make this happen Collision Event with object obj14: execute code: ///make this happen Collision Event with object obj15: execute code: ///make this happen Collision Event with object obj16: execute code: ///make this happen Collision Event with object obj17: execute code: ///make this happen Collision Event with object obj18: execute code: ///make this happen Collision Event with object obj19: execute code: ///make this happen Collision Event with object obj20: execute code: ///make this happen Collision Event with object obj21: execute code: ///make this happen Collision Event with object obj22: execute code: ///make this happen Collision Event with object obj23: execute code: ///make this happen Collision Event with object obj24: execute code: ///make this happen Collision Event with object obj25: execute code: ///make this happen Collision Event with object obj26: execute code: ///make this happen Collision Event with object obj27: execute code: ///make this happen Collision Event with object obj28: execute code: ///make this happen Collision Event with object obj29: execute code: ///make this happen Collision Event with object obj30: execute code: ///make this happen Collision Event with object obj31: set the health relative to -5 Keyboard Event for Key: execute code: image_xscale = -1; physics_apply_force(x,y, -move_speed, -20); Keyboard Event for Key: execute code: image_xscale = 1; physics_apply_force(x,y, move_speed, -20); Other Event: Outside Room: execute code: phy_position_x = start_x; phy_position_y = start_y; if next room exists Go to next room Draw GUI Event: execute code: draw_text(0,0,"Fps:"+string(fps)+"/"+string(room_speed)) Key Press Event for Key: execute code: ///First Jump if (place_meeting(x,y+1, obj_Collision)) { jumping = true; alarm [0] = 1; physics_apply_impulse(x,y,0, jump_force); show_debug_message("First Jump") } execute code: /// Secound Jump if(jumping && alarm[0] < 0){ physics_apply_impulse(x,y,0, jump_force); jumping = false; show_debug_message("Double Jump") } GML
Administratorzy gnysek Opublikowano 3 Września 2014 Administratorzy Opublikowano 3 Września 2014 Po pierwsze, sprawdź ile jest instancji w roomie. Po drugie - jak masz tyle eventów kolizji, to może być to.
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 Kurcze jak mam te instancje sprawdzić w roomie? no mam tyle obiektów,to mam je pousuwać???
Administratorzy gnysek Opublikowano 3 Września 2014 Administratorzy Opublikowano 3 Września 2014 instance_count , jest taka zmienna. Nie wiem co tam masz za kod, ale jak mówię - jak jest dużo kolizji i jeszcze każdy z każdym, to gra będzie mulić, niestety.
Cygnus Opublikowano 3 Września 2014 Autor Opublikowano 3 Września 2014 To powiedz mi,mam pousuwać te kolizje? no tak jak mówisz,to przez to muli:/
Cygnus Opublikowano 4 Września 2014 Autor Opublikowano 4 Września 2014 Kurcze pousuwałem klizję z innymi objektami,ale to nie pomaga,to nie od tego tak wolno chodzi 2 lub 4 klatki na sekunde nie idzie nic zrobic:/ pomóżcie..
Cygnus Opublikowano 5 Września 2014 Autor Opublikowano 5 Września 2014 Proszę Panie Uzjel;) Kurcze nie wiem,co jest nie tak,te 3 pokoje działają bardzo dobrze,a ten ostatni wyciąga 2 lub 4 klatki:/ maks:/ Kolizje pousuwałem z objektami to dalej nie pomaga:/ Obj_Player CREATE GML [/gml] start_x = x; start_y = y; phy_fixed_rotation = true; move_speed = 200; max_xspeed = 2; jumping = false; jump_force = -95; [gml] STEP GML [/gml] phy_speed_x = max(min(phy_speed_x, max_xspeed) , -max_xspeed); if(phy_speed_x > 0.1 || phy_speed_x < -0.1) { sprite_index = spr_Player_Running; } else{ sprite_index = sprPlayer; } if (phy_speed_y > 1.2) { sprite_index = spr_Player_Falling; } image_speed = phy_speed_x / 10; background_x[0] = -phy_position_x / 5; background_x[0] = -phy_position_y / 5; background_x[1] = -phy_position_x / 5; background_x[1] = -phy_position_y / 5; [gml] Outside Room GML [/gml] phy_position_x = start_x; phy_position_y = start_y; [gml] Draw Gui GML [/gml] draw_text(0,0,"Fps:"+string(fps)+"/"+string(room_speed)) [gml] Tu całe info z show information GML [/gml] Information about object: obj_player Sprite: sprPlayer Solid: false Visible: true Depth: 0 Persistent: false Parent: Mask: spr_wall Physics Start Awake: true Is Kinematic: false Is Sensor: false Density: 1 Restitution: 0.1 Group: 0 Linear Damping: 1 Angular Damping: 0.1 Friction: 0.1 Shape: Box Points: (3.25, 0) (30, 0) (30, 30) (3.25, 30) Create Event: execute code: start_x = x; start_y = y; phy_fixed_rotation = true; move_speed = 200; max_xspeed = 2; jumping = false; jump_force = -95; set the health to 100 Alarm Event for alarm 0: execute code: ///make this happen Step Event: execute code: phy_speed_x = max(min(phy_speed_x, max_xspeed) , -max_xspeed); if(phy_speed_x > 0.1 || phy_speed_x < -0.1) { sprite_index = spr_Player_Running; } else{ sprite_index = sprPlayer; } if (phy_speed_y > 1.2) { sprite_index = spr_Player_Falling; } image_speed = phy_speed_x / 10; background_x[0] = -phy_position_x / 5; background_x[0] = -phy_position_y / 5; background_x[1] = -phy_position_x / 5; background_x[1] = -phy_position_y / 5; if health is smaller than 1 jump to the start position restart the game Collision Event with object obj_Collision: execute code: ///make this happen Collision Event with object obj_kamien: execute code: ///make this happen Collision Event with object obj_centralnyPrawy: execute code: ///make this happen Collision Event with object obj_kolce: set the health relative to -5 Collision Event with object obj_enemy: set the health relative to -1 Collision Event with object obj_skosikowy: execute code: ///make this happen Collision Event with object obj_platformaTrawaM: execute code: ///make this happen Collision Event with object obj_skosikP: execute code: ///make this happen Collision Event with object obj_woda: set the health relative to -5 Collision Event with object obj23: execute code: ///make this happen Collision Event with object obj31: set the health relative to -5 Keyboard Event for Key: execute code: image_xscale = -1; physics_apply_force(x,y, -move_speed, -20); Keyboard Event for Key: execute code: image_xscale = 1; physics_apply_force(x,y, move_speed, -20); Other Event: Outside Room: execute code: phy_position_x = start_x; phy_position_y = start_y; if next room exists Go to next room Draw GUI Event: execute code: draw_text(0,0,"Fps:"+string(fps)+"/"+string(room_speed)) Key Press Event for Key: execute code: ///First Jump if (place_meeting(x,y+1, obj_Collision)) { jumping = true; alarm [0] = 1; physics_apply_impulse(x,y,0, jump_force); show_debug_message("First Jump") } execute code: /// Secound Jump if(jumping && alarm[0] < 0){ physics_apply_impulse(x,y,0, jump_force); jumping = false; show_debug_message("Double Jump") } [gml]</span>
Administratorzy gnysek Opublikowano 5 Września 2014 Administratorzy Opublikowano 5 Września 2014 No ciężko stwierdzić o co chodzi, skoro pokazujesz 1 obiekt, a w roomie masz pewnie sporo i zapewne to jest tego przyczyną.
Cygnus Opublikowano 5 Września 2014 Autor Opublikowano 5 Września 2014 To co mam zrobić żeby to pokazać żeby wiadomo było co jest nie tak:/?
Cygnus Opublikowano 6 Września 2014 Autor Opublikowano 6 Września 2014 No właśnie ,jak to zrobić? gdzie ta opcja żeby to zgrać?
Sutikku Opublikowano 6 Września 2014 Opublikowano 6 Września 2014 Nie jestem pewien czy to tak właśnie wygląda, ale chyba tak Menu->Eksportuj->GMZ Mogę się mylić ;c
Cygnus Opublikowano 6 Września 2014 Autor Opublikowano 6 Września 2014 Proszę Panowie..tu link do mojej gry Zerknijcie,co jest nie tak,teraz coś poknociłem i wcześniej działał w żółwim tempie ten ostatni pokój,a teraz już błąd wywala:/ I jak możecie zobaczcie jak to zrobić,że jak przechodzi do drugiego roomu,to w konkretnym miejscu,a nie,gdzie się obróci na koniec planszy,to może przejść bezproblemowo do następnego roomu. Tu link do mojej gry Odwiedź moją stronę
Rekomendowane odpowiedzi
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto
Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.
Zarejestruj nowe konto
Załóż nowe konto. To bardzo proste!
Zarejestruj sięZaloguj się
Posiadasz już konto? Zaloguj się poniżej.
Zaloguj się