Dragging and dropping stuff from one game to another

FrantoFranto Member Posts: 779

This is a feature exclusive to Mac I believe? As you can't open two games at once in Windows last time I checked{I haven't checked recently.}

How does this work? What are the risks?

People talk about dragging code from one game to another, but won't this overlap other attributes and cause some errors? Are new attributes created?

Dragging select portions of a game into an empty game sounds simpler?

I ask because I'm thinking about doing that for my game, just dragging all relevant parts of it to an empty game? But fear that it may not work out because of some unforeseen thing, then I would end up wasting an hour or two. I can't find info when searching for it, just about drag and drop games.

Comments

  • ArmellineArmelline Member, PRO Posts: 5,368

    If you drag and drop, it can work very well. But there are definitely some considerations:

    • Any actors you drag into the new projects will only remain valid with non-editable game attribute and self attribute references. So if you have a change attribute that points to a game attribute, this will of course not work
    • Any self-attributes will be copied over
    • There is no major risk of clashing attributes - the chance of a clash happening is low, and if it does you just have to manually change either the old references or new references.
    • In very complex games, it's probably easier to save a copy of the game and manually remove everything that isn't needed
  • FrantoFranto Member Posts: 779

    @Armelline Do any of their rules that reference an attribute get a broken link like "invalid attribute". I would think this would happen if I drag the actors before the game attributes they use. I just remember the closest windows has to this mac feature is if you save a rule, and load another game, that rule will be in the custom rules, but when you drag it to your game, even if you have a same name game attribute, the link in the rules are still broken. I guess you would need the exact same "id" the system uses in the previous game for that attribute.

    That is good to know about self-attributes and attributes not clashing.

    My game is quite complex, so you might have a point and I will just have to manually remove things.

    I do have the urge to remake, simplify, and organize the system to run in a different, more modular system, so I think I will save that effort for the sequel, and release this game with the system as it is. Just gotta put in iAP and finish some levels.

  • ArmellineArmelline Member, PRO Posts: 5,368

    If a rule or behaviour references an attribute that isn't copied over - game and scene attributes - it will just lead to a pop-up (on Mac at least) informing you of the broken attributes and then it will leave any references blank (or replace with a 0 in expression editor).

    To have it maintain game attributes you'll indeed need the exact same "id". Which will take longer than it's worth to set up in the XML files.

    If your game is complex, removing things is definitely the way to go.

  • FrantoFranto Member Posts: 779

    @Armelline Thanks, I think I will have to do that then. Or at least save the dragging and dropping for a sequel where I want to replace the game attributes entirely.

Sign In or Register to comment.