GUI implementation of object types in 4.x
xordevoreaux
03 Oct 2010, 14:24When I'm in Visual Studio, and I have an object defined of a given type, and that type has properties, it's easy to override those properties because Visual Studio displays them for you; you don't need to run back to the object's class to figure out which properties you included with that class.
So for example, I created an NPC type in QuestPro 4.1.2, and I added the properties hostile, maxhealth = 15, currenthealth = 15;
Then I have my rat object that I created, npc_rat_1, and assigned NPC as its object type, wanting then to go into npc_rat_1's properties to modify hostile/not hostile, maxhealth = 10, currenthealth = 10.
I pulled up the Properties and Actions window for npc_rat_1, and saw no properties listed, despite it being of type NPC. I figured at that point were I simply to re-add the properties from the original object type to the object, that the game would parse those and not the default object type's version. Didn't test it but I trusted that would be the case.
I was about to do just that, and add the properties again to npc_rat_1 that I set up for NPC, but the problem, I realized, is that as my NPC object type grew over time and I added more properties and the NPC object type became more complex, I would be staring at blank Properties and Actions windows for objects assigned to NPC, and I'd have to close the window, go back to the object type's definition, open it up, glance to see what the properties are there, try to remember some of them from the list, run back to the actual object, open up the Properties and Actions window, re-add what I could remember what I saw a moment before from the object type's Properties and Actions window, and do that ad nauseum until I had everything overridden. Bleh.
Better if I could see the inherited properties listed in that particular object's Properties and Actions window, so I could just run down the list of the object's inherited properties and tweak as I go along, rather than having to re-create the list of properties per object every time.
So for example, I created an NPC type in QuestPro 4.1.2, and I added the properties hostile, maxhealth = 15, currenthealth = 15;
Then I have my rat object that I created, npc_rat_1, and assigned NPC as its object type, wanting then to go into npc_rat_1's properties to modify hostile/not hostile, maxhealth = 10, currenthealth = 10.
I pulled up the Properties and Actions window for npc_rat_1, and saw no properties listed, despite it being of type NPC. I figured at that point were I simply to re-add the properties from the original object type to the object, that the game would parse those and not the default object type's version. Didn't test it but I trusted that would be the case.
I was about to do just that, and add the properties again to npc_rat_1 that I set up for NPC, but the problem, I realized, is that as my NPC object type grew over time and I added more properties and the NPC object type became more complex, I would be staring at blank Properties and Actions windows for objects assigned to NPC, and I'd have to close the window, go back to the object type's definition, open it up, glance to see what the properties are there, try to remember some of them from the list, run back to the actual object, open up the Properties and Actions window, re-add what I could remember what I saw a moment before from the object type's Properties and Actions window, and do that ad nauseum until I had everything overridden. Bleh.
Better if I could see the inherited properties listed in that particular object's Properties and Actions window, so I could just run down the list of the object's inherited properties and tweak as I go along, rather than having to re-create the list of properties per object every time.
Alex
03 Oct 2010, 17:56You're right, it would be a better design to be able to see the inherited properties within the editor. This is what I'm planning for Quest 5.0 - so far, in the debugger when the game is playing, you can see the inherited properties greyed out. I'm currently working on the Editor and plan to have a similar setup there.