Snowblossom Wavy Movement for Falling Down?

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
mitoky
Veteran
Posts: 316
Joined: Sat Feb 07, 2015 9:12 pm
Projects: The Purring Demon's Love, circus eterie
Contact:

Snowblossom Wavy Movement for Falling Down?

#1 Post by mitoky »

Hello!

I am trying to get feathers to fall down. While doing so they are supposed to slightly move left and right like it would be "floating" down while tilting slightly left and right. While the tilting works, i cant get it to move left and right. I am using Snowblossom and atl:

Code: Select all

image feather = Fixed(
    SnowBlossom(At("feather1.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=False),
    SnowBlossom(At("feather2.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=False),
    SnowBlossom(At("feather3.png", feather_movement), count=30, xspeed=(0), yspeed=(80, 150), start=30, fast=False, horizontal=False))

Code: Select all

transform feather_movement:
    parallel:
        linear 2.0 rotate -30
        linear 2.0 rotate 30
    parallel:
        ease 2.0 xoffset -300
        ease 2.0 xoffset 300
    repeat
I am new to coding, so either i am thinking too simple or i made a mistake, so i would really appreticiate help!

User avatar
Potato0095
Regular
Posts: 84
Joined: Sun May 08, 2016 8:40 pm
Projects: LoveCraft
itch: potato95
Location: Brazil
Contact:

Re: Snowblossom Wavy Movement for Falling Down?

#2 Post by Potato0095 »

Well, if you're still looking for the answer (sorry for answering 4 months later), try changing the variable "horizontal" to True.

Code: Select all

image feather = Fixed(
    SnowBlossom(At("feather1.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=True),
    SnowBlossom(At("feather2.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=True),
    SnowBlossom(At("feather3.png", feather_movement), count=30, xspeed=(0), yspeed=(80, 150), start=30, fast=False, horizontal=True))
"There are two types of lies: Lies that hurt, and lies that don't."

User avatar
mitoky
Veteran
Posts: 316
Joined: Sat Feb 07, 2015 9:12 pm
Projects: The Purring Demon's Love, circus eterie
Contact:

Re: Snowblossom Wavy Movement for Falling Down?

#3 Post by mitoky »

Potato0095 wrote: Sat Feb 24, 2018 4:50 pm Well, if you're still looking for the answer (sorry for answering 4 months later), try changing the variable "horizontal" to True.

Code: Select all

image feather = Fixed(
    SnowBlossom(At("feather1.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=True),
    SnowBlossom(At("feather2.png", feather_movement), count=20, xspeed=(0), yspeed=(80, 150), start=20, fast=False, horizontal=True),
    SnowBlossom(At("feather3.png", feather_movement), count=30, xspeed=(0), yspeed=(80, 150), start=30, fast=False, horizontal=True))
Unfortunally, it doenst work. I appreticiate the help though (:

User avatar
Lord Hisu
Regular
Posts: 58
Joined: Sun Feb 11, 2018 2:31 am
Contact:

Re: Snowblossom Wavy Movement for Falling Down?

#4 Post by Lord Hisu »

If I understand that right, you want your images to go left to right, right to left, and then repeat. The problem is SnowBlossom defines a random initial velocity for x and y, so I think you can't just mess with the position of the particles yourself, because the class handles it (I'm not sure though).

I'm pretty sure I could write a class for you to do that, but the new class should be derived from SpriteManager, and I'm just starting to grasp how to work with it, so I'm not so confident yet to share examples. I could try in the near future, though.

User avatar
mitoky
Veteran
Posts: 316
Joined: Sat Feb 07, 2015 9:12 pm
Projects: The Purring Demon's Love, circus eterie
Contact:

Re: Snowblossom Wavy Movement for Falling Down?

#5 Post by mitoky »

Lord Hisu wrote: Sat Mar 24, 2018 2:59 am If I understand that right, you want your images to go left to right, right to left, and then repeat. The problem is SnowBlossom defines a random initial velocity for x and y, so I think you can't just mess with the position of the particles yourself, because the class handles it (I'm not sure though).

I'm pretty sure I could write a class for you to do that, but the new class should be derived from SpriteManager, and I'm just starting to grasp how to work with it, so I'm not so confident yet to share examples. I could try in the near future, though.
That makes sense. Please dont mind it, for now i have something else in my project planned so the issue is not pressing.
However, if you ever happend to find a way, or someone else, then i would appreciate it for future reference. (:

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot]