Playmaker Forum

PlayMaker Updates & Downloads => Share New Actions => Topic started by: blackant on February 22, 2019, 04:22:45 AM

Title: An Action to set a sprite height and rotation
Post by: blackant on February 22, 2019, 04:22:45 AM
Hello,

i started creating an action that would allow us to resize a sprite between 2 points.

i use it to let the player see the first clic with right mouse bouton, and the distance with actual mouse.x position to rotate the camera.

the script is actually not completed and i would like to have some help from more advanced people to make something great.

on the screenshot you may see the debug line in the scene view, wich is the desired result of course, and the game view has some problems with angle and sprite size must have height of 10 to get the right scale on Y.
(https://i.pinimg.com/originals/db/6b/65/db6b656849ec33550f9ea35641a7b579.png)
i have attached the script if someone can complete it or help with advises.
Title: Re: An Action to set a sprite height and rotation
Post by: jeanfabre on March 05, 2019, 12:30:44 AM
Hi,

 did you make some progress on this or are you still stuck?

 Bye.

 Jean
Title: Re: An Action to set a sprite height and rotation
Post by: blackant on March 05, 2019, 01:26:26 AM
no progresse on it, i didn't had time to reopen this project.
Title: Re: An Action to set a sprite height and rotation
Post by: jeanfabre on March 27, 2019, 06:04:00 AM
Hi,

Ok, so I made two new actions to get and set sprite sizes, and I also made a quick scene to show how to control the sprite to have it move, rotated and sized properly between two points.


 Let me know if you have questions.

Bye,

 Jean
Title: Re: An Action to set a sprite height and rotation
Post by: blackant on March 27, 2019, 04:57:46 PM
Thanks Jean,

i tested but it looks bumpy when you make quick moves.
i'll try to find a smoother way to get accurate result.
Title: Re: An Action to set a sprite height and rotation
Post by: jeanfabre on March 28, 2019, 03:26:09 AM
Hi,

 yep, that's why they made the line renderer, because 2d sprites are not aliased, you can alias it but only with post processing.

 Bye,

 Jean
Title: Re: An Action to set a sprite height and rotation
Post by: blackant on April 02, 2019, 12:08:14 PM
i mean jiggly when you move the spot fast or not

or maybe it's a bug on my version
Title: Re: An Action to set a sprite height and rotation
Post by: jeanfabre on April 03, 2019, 01:59:06 AM
Hi,

 yes, that's what I meant, 2d sprites are not alias like 3d object, you need a post processing effect, else you need to use a different technic.

 Bye,

 Jean