Can't create object...need help please

  • Just starting out and want to learn as much by myself as possible, so looking for direction.

    I have a row of sprites (balls numbered 1 to 18) set up at the bottom of my screen. I want to use drag and drop to move it to another area, which works fine. However, I want to leave a copy of the original ball in its original position. I want this because each sprite can be used multiple times.

    I thought I'd have to use spawn but read elsewhere here that CreateObject may be better. Here's the code I have:

    System: currentlyDragging=0

    Mouse: Cursor is over sk1: sk1-set beingDragged to True

    sk1: Is beingDragged: System-Create object sk1 on layer 0 at (40,400)

    I'm sure I have the right layer (I only have 1), but the new sprite is never created. Is the code inserted at the wrong point perhaps?

    Anyway, thanks in advance for any help.

  • Sharing your .capx might help.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hey Ashley, I figured out what the problem was and fixed it.

    You're right...next time I'll add the .capx.

    Thanks for replying just the same...much appreciated.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)