Posted: Sat May 23, 2009 7:46 am
I know I'm bumping a thread many many moons old, down to the years, but I believe slices can make many things about a Rogue like realistically possible.
Basically, the problem with items is that you either can't have unique properties of the same type of item, or you have to eat quite a few globals or use menu slots to have an inventory system.
I figured out today that Slices can be used for "fake object oriented" scripting purposes, meaning that if needed, they can be used just for storing data, and conserving globals at that. Here's how:

Basically, the only global necessary would actually be the parent, since it can just create children slices that are attached to it. With each item being an individual slice with variables that alter its properties, this system would allow a way for every item to be completely unique even if they are the same type.
And if three extras aren't enough, TMC said that you can use many other variables that slices have if you are willing to use specific commands to access such variables and use them for different purposes, or each item could have its own child that you can use for more extra data if necessary.
Basically, the problem with items is that you either can't have unique properties of the same type of item, or you have to eat quite a few globals or use menu slots to have an inventory system.
I figured out today that Slices can be used for "fake object oriented" scripting purposes, meaning that if needed, they can be used just for storing data, and conserving globals at that. Here's how:

Basically, the only global necessary would actually be the parent, since it can just create children slices that are attached to it. With each item being an individual slice with variables that alter its properties, this system would allow a way for every item to be completely unique even if they are the same type.
And if three extras aren't enough, TMC said that you can use many other variables that slices have if you are willing to use specific commands to access such variables and use them for different purposes, or each item could have its own child that you can use for more extra data if necessary.