Jump to content
A 2021 backup has been restored. Forums are closed and work in progress. Join our Discord server for more updates! ×
SoaH City Message Board

Object... Foresight? I guess...


TailsSena

Recommended Posts

Mmkay, so. The problem...

I need to create a line of code that can handle objects that don't exist in the frame editor. (And probably never will.)

I'm trying to make it understand that I'm going to be managing many instances of the same object, all doing completely different things... And I have no way of knowing when or even if these objects will ever exist, so creating a bunch of cloned objects and coding them all is an incredible waste of my time...

Does anybody understand what I'm trying to say, or can anybody help with the matter...

I'm beginning to think of DW's tutorials on Instancing, but I'm not sure... Again, I don't recall those going over objects that aren't guaranteed to exist.

Link to comment
Share on other sites

The easiest way to do this is to simply have the object in the frame at the start and have an event at the beginning to delete all instances of the object.

There are two other ways to do it though. The first is to have a separate frame where you store a single instance of each object and to do all your coding in object behaviors. Then when you want to use it, you simply create the object from that frame in the frame you are actively using.

The other way to do it is to import the object into the event editor from another frame and to code everything from there, but that sucks sooooo much more than just deleting the objects at the beginning.

Link to comment
Share on other sites

Yeah... Really with there was an option to say "Pick from instance line," especially since the Debugger shows me that they're all named with numbers.

So, delete all of them at the beginning... Or just don't create them until I need them, right? Disable the "Create at start." That could even speed things up by like, a plank time or two... Well, actually several fuck-a-jillion*, but you get the point.

*(Too many zeros to count.)

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...