Jump to content
A 2021 backup has been restored. Forums are closed and work in progress. Join our Discord server for more updates! ×
SoaH City Message Board

(GML)Make Rolling not effected by Image_Angle


trublu45458

Recommended Posts

However exactly do you mean 'not affected by'? Does the engine rotate Sonic's sprite depending on the angle of the hill, and you don't want that to happen?

I can't find this engine you're talking about it; could you post code snippets involving image_angle?

Link to comment
Share on other sites

I think he definatly means not for it to rotate when on a loop or a angle greater than or lower than 0 degrees. Since most of us aren't GM experts I would recommend you posted this same topic on GameMaker Forums which can be found here : http://gmc.yoyogames.com/ . There is always someone who can help and knows exacly what you want.

If this was MMF2 I'd probably say you'd have to find the command or line which makes him do this action and then try to make it so when it's active + touching the floor = make sonics angle 0 degrees. I'm not sure how it exacly works in GM but I have a feeling it's the same idea.

PS: I'm not trying to draw him away from this forum, just suggestion more help.

Link to comment
Share on other sites

  • 5 months later...

I finally came back to sfghq because I finally remembered what my password was =p.

I need Sonic's spin sprites to not rotate while on loops or slopes, just to stay straight like a Sonic game.

The engine name is exactly Sonic Revival Unleashed Engine BETA 4, on his forum there is a broken link, scroll down to the post that says "and the beta 4:" or something close, and there is a working link.

Theres also an original one called Sonic Revival, and a updated one called Sonic REX.

Link to comment
Share on other sites

new problem.

the code if action=action_rolling angle=0; by itself fixes my angle issue perfectly, except for some reason Sonic can no longer go up slopes more than about 45 degrees. He just gets stuck until he goes to 0 speed or jumps. Jumping makes him go very high, due to momentum coding. He can go down any angle of slope though. I tried putting it in Step and End Step but no cigar.

Link to comment
Share on other sites

A quick method to do this is picking this code at the end of "End Step" event:

if action=action_rolling angle=0;

Good Luck

oOmg Kirs, nooob!! wtf are you saying?? that line will cause a lot of problems!

Sry, that method was too fast... and wrong... till we make something to fix it.

Remove that line and make this:

First lines of draw event:

angle_hold=angle

if action=action_rolling angle=0;

Last line of draw event:

angle=angle_hold

It's the same method, but now we store the angle value before change it in the case that sonic is rolling. In that case, sonic's sprite will de drawn at angle 0 but after that, we restore the previous angle value to allow sonic's normal movement.

Hope that helps a bit more : /

  • Like 1
Link to comment
Share on other sites

Much simpler idea.

if action = action_rolling

{image_angle = 0}

Although I have no experience with the Revival engine this may help.

That dosnt work since Sonic have a draw event and rotates over 'angle' variable on draw_sprite_ext script, not image_angle.

THANK YOU THANK YOU KIRS!

You fixed my biggest problem!

+rep

nope =)

PD

That title just gave me an aneurysm.

The author of the engine gives thanks to that comment and is happy about ur aneurysm ^^

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...