[Not Equal To Instance Variable] Set Frame?

Get help using Construct 2

Post » Mon May 04, 2015 12:16 pm

Hey folks,

So I have a quick question. I've scoured the forums and I'm starting to wonder if what I want to do is even possible. Here is, essentially, what I want to happen:

Object "ELIZ" sets its frame to a random frame out of 20 [ random(0, 20) ]. However, I don't want it to set the frame to its current frame at any time. SO, I have created an instance variable called "frame".
What I want the code to look like is, basically:

Set frame to a random frame between 0 and 20, but NOT equal to the current frame.

I can't find a way to do this, however. I'm open to workarounds, of course, but there doesn't seem to be one that I can find. Any help would be much appreciated! Been stumped on this bit for a while, now.

Thanks!
B
3
Posts: 6
Reputation: 212

Post » Mon May 04, 2015 1:02 pm

Last edited by chrisinfinger on Mon Sep 05, 2016 3:35 pm, edited 2 times in total.
Check out my completed games on the Arcade! Capt. Doe Save the Universe! & Clicker Wizard!
B
71
S
19
G
8
Posts: 640
Reputation: 9,701

Post » Tue May 05, 2015 2:35 am

Works like a charm! Thank you so much!
B
3
Posts: 6
Reputation: 212


Return to How do I....?

Who is online

Users browsing this forum: hellokitty1, Julot135, newt and 28 guests