safely removing ace items

Forum for plugin, effect and behavior programmers. Please use the Help & Support forum for help using Construct.

Post » Thu Feb 24, 2011 10:01 pm

I know if you add an ace item in between two others on the ace table, and then load a cap made with the previous version of a plugin, it will mix up your actions.

EDIT: forget what I said about physics. I fixed that. but still curious if it's possible to remove something from the ace table without breaking old caps
Spriter Dev
B
88
S
21
G
12
Posts: 3,240
Reputation: 16,486

Post » Wed Mar 02, 2011 7:16 pm

You could use "ADDCND_AT", "ADDACT_AT" and "ADDEXP_AT" defined in "\Common\CommonAceTable.hpp" instead of "ADDCND", "ADDACT" and "ADDEXP". That way you can manually assign an index to the ace.
By default common aces are indexed 0-255, and any plugin defined aces start at 255. So the first plugin condition will be 255, also the first action will be 255.
B
79
S
24
G
54
Posts: 4,753
Reputation: 40,769

Post » Wed Mar 02, 2011 7:29 pm

You can't remove from the ACE table without breaking caps - this is a design flaw in 0.x that's been corrected in C2 (your ACE table can be in any order and you can mark obsolete ACEs as deprecated, so they still work in old projects but can't be chosen through the UI). R0J0's workaround is the best you can do. You shouldn't change it though, 0.x uses the ACE table indexes to reference everything.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600


Return to Construct engineering

Who is online

Users browsing this forum: No registered users and 1 guest