SOLVED-Copy sprites from another layout at runtime

This forum is currently in read-only mode.
  • Is that possible? I mean: If you have a Street Fighter game, can you load characters and scenes based on previews character selection menu?

    I know that you can load from images on hd, but would be great to load from another layout, where you have the character already constructed.

    Any alternative?

  • Hi Aritz.

    In your event sheet all you need do is create the condition for which you want to create the character (eg. on start of layout) then select 'Create Object' under 'System'. Then just choose the character and select the location :)

    The best way to handle this however is to probably create a 'spawn' object and copy this across layouts and make an event that spawns that character at that object, then include that event sheet in each layout so you don't have to worry about it each time. Hope that's helpful!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • With 'Create Object' or 'Spawn Object' you can only create or duplicate objects existing in the current layout.

  • You can either make the event in the event sheet of the layout with the object or an event sheet not tied to any layout (they list all objects) and copy it over, or you can temporarily make the object global, listing it in all layouts, make the event, then turn it not global again.

  • Sorry I meant to state that I did mean in a non layout-linked event sheet, oops!

  • Thanks, I have solved it using "Load/unload layout textures" action. It loads any object from another layout, so you can make layout as a sprite palettes to load sprites as needed.

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