I Wanna Community

Object Wobble Effect

0 Members and 1 Guest are viewing this topic.

Offline StuffandThings

  • 17
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Chrome 52.0.2743.116 Chrome 52.0.2743.116
  • Playstyle: Keyboard
Object Wobble Effect
« on: September 10, 2016, 01:23:10 PM »
I tried out Klazen's 'wobble' code:
(click to show/hide)

but I want to use it in a slightly different way. I'm trying to figure out how to set it up so that you place an instance in the room, and edit the creation code to have the same effect. It seems that this way, any instance you place will have the same properties and the wobbles will be in-sync. But what if I wanted to control each instance, and make them all wobble differently (instead of making more objects)?

I tried to setup some variables to call from the creation code but I keep getting an error saying "objWobble.(variable) not set before reading it."  I tried something along the lines of this:
(click to show/hide)

I know the variables have to be initialized first, but even when I did get GM to accept the code, there was no wobble. How would I set this up?

Offline WetWookie

  • 90
  • OS:
  • Windows 10 Windows 10
  • Browser:
  • Firefox 48.0 Firefox 48.0
  • Playstyle: Keyboard
Re: Object Wobble Effect
« Reply #1 on: September 10, 2016, 01:28:41 PM »
In studio the Creation Code takes place after the Create Event so all you have to do are give wobble_speed and/r wobble_distance a different value in the instances creation code. (ie. wobble_distance = 64);

Offline StuffandThings

  • 17
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Chrome 52.0.2743.116 Chrome 52.0.2743.116
  • Playstyle: Keyboard
Re: Object Wobble Effect
« Reply #2 on: September 11, 2016, 12:25:30 AM »
wow...I was making that way more complicated than necessary haha. Thanks!

Offline L4Vo5

  • 59
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Chrome 52.0.2743.116 Chrome 52.0.2743.116
  • Playstyle: Keyboard
Re: Object Wobble Effect
« Reply #3 on: September 12, 2016, 11:53:08 PM »
You can also change aa to make them start desynchronised
I have to admit, i still haven't beaten IWBTG