Misc. Questions

If you wish to contribute to the Ace Attorney Online Game Creation Engine open source project, or just know more about the way it is developed, this is the place.

Moderator: EN - Forum Moderators

User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

By the looks of it, here are the things that aren't supported in mocked install: Playtesters/Collaborators, Sequences, Forum, Backups.

Is that how it's supposed to be? If so, then I'm ready to call the mocked install fully operational.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
kwando1313
Posts: 7684
Joined: Tue Jul 22, 2008 6:33 pm
Gender: Male
Spoken languages: English, Français (un peu), Ancient Belkan
Location: Uminari City

Re: Misc. Questions

Post by kwando1313 »

Unas wrote:Scope of test :
Game creation, edition and playthrough : all trial management operations that can be done by a user alone.
No user account management, hence no collaboration, etc.
I'd say yes.
Avatar made by Rimuu~

Image

"The Knight of the Iron Hammer, Vita, and the Steel Count, Graf Eisen. There's nothing in this world we can't destroy."
AceAttorneyMaster111
Posts: 468
Joined: Sat Sep 27, 2014 6:46 pm
Gender: Male
Spoken languages: English, français, un poco de español, עברית
Location: USA

Re: Misc. Questions

Post by AceAttorneyMaster111 »

I'm pretty sure that trial series falls under single-user trial-making.
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

I'm planning on working on Issue #2, the rowmap bug. As that involves some code that is both extreme complicated and extremely complex, I'm planning on doing some rewriting as I go. How frequently should I commit the rewrites? For example, the first change I'm planning on is refactoring Interval's start, end, and empty properties to start and length. Should I commit that as soon as I've done it, or add a few more changes before committing? The former would be commit spam, but the latter will quickly become inscrutable.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
Unas
Admin / Site programmer
Posts: 8850
Joined: Tue Jul 10, 2007 4:43 pm
Gender: Male
Spoken languages: Français, English, Español
Contact:

Re: Misc. Questions

Post by Unas »

Enthalpy wrote:By the looks of it, here are the things that aren't supported in mocked install: Playtesters/Collaborators, Sequences, Forum, Backups.

Is that how it's supposed to be? If so, then I'm ready to call the mocked install fully operational.
Sequences should work as far as I know. Do you have any specific issue with those ?

As for backups, they should work too, they do not even depend on the database. If you don't get any backup, it might be some config issue, like the backups directory being badly set in config; or simply not existing.

Enthalpy wrote:I'm planning on working on Issue #2, the rowmap bug. As that involves some code that is both extreme complicated and extremely complex, I'm planning on doing some rewriting as I go. How frequently should I commit the rewrites? For example, the first change I'm planning on is refactoring Interval's start, end, and empty properties to start and length. Should I commit that as soon as I've done it, or add a few more changes before committing? The former would be commit spam, but the latter will quickly become inscrutable.
Ah, I've forgotten to do the fix indeed...
The fix is supposed to be simple enough, as per my analysis here : http://aceattorney.sparklin.org/forum/v ... p?p=727896
I should probably do it myself though, if I found the time.

That being said, it's generally a bad idea to do bugfixing at the same time as refactoring. It makes it terribly hard to test your changes.
As a general rule, refactoring should maintain the existing functionality as much as possible : any difference in behaviour caused by the refactoring is a potential bug. You could write tests that ensure you don't cause any difference between both versions of the code.
If you try to do bugfixes at the same time, however, it becomes much more difficult, since some differences may be wanted while some others may be errors during the refactoring.

So, one thing at a time please; especially when tackling a piece of code that you don't know that well ;-)
ImageImageImage
If knowledge can create problems, it is not through ignorance that we can solve them.
Si le savoir peut créer des problèmes, ce n'est pas l'ignorance qui les résoudra. ( Isaac Asimov )
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

I have backups working now (the backups folder simply wasn't in mocked_install/trial_data, and touch won't make a folder for you), but attempting to create a series raises the error that SQLite doesn't know the FIND_IN_SET function. I assume that one is unavoidable.

Now for a few more miscellaneous questions...
* For issue 127, what is the expected behavior? The is_array check of db_op 188 suggests that no sequence should be created, but I'm not sure why you wouldn't allow an empty sequence. Perhaps this creates some issue in the series handling system?
Answered here, thank you!
* I can accept leaving the row maps alone for a while if you'll handle Issue #2, but I'm stuck on how to actually learn this code. I've tried going through the debugger with it, reading it, annotating it, and taking a break before continuing with it, but I never seem to get anywhere with it. My plan was to refactor it first into a form I could understand more clearly, ensure all those commits worked, and then deal with the bug, but if that's not an option, I'm not sure what else I can do.
EDIT: And never mind that one either! When I finally figured out that an interval represents a series of rows that are contiguous in the trial data and meant to be displayed contiguously, a lot of the rest clicked. There's still a lot to go, but the basic ideas are much clearer. ... Though I'm still not planning to touch Issue #2 until I know the row maps much much better.
* Assuming I should stay away from the row maps, how was the v5 serie_proces array created? I'll need that to try and fix bug 38. My intuition is that it's the trial_id_by_pos list of TrialSequenceHandlerV5's getIdOfEltAt, but I'd like to confirm.

Thanks again for all of this.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

About Issue 141. Do we want the wrapped versions of push and splice to return values, like the non-wrapped versions do? It's a fairly simple change, while I'm at it.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
Unas
Admin / Site programmer
Posts: 8850
Joined: Tue Jul 10, 2007 4:43 pm
Gender: Male
Spoken languages: Français, English, Español
Contact:

Re: Misc. Questions

Post by Unas »

Yes, wrapped methods should behave exactly like the original ones from an outsider's perspective. So yes, adding that is a welcome change !
ImageImageImage
If knowledge can create problems, it is not through ignorance that we can solve them.
Si le savoir peut créer des problèmes, ce n'est pas l'ignorance qui les résoudra. ( Isaac Asimov )
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

The #141 fix is up, and hopefully it's good enough. The #5 semicolons have been added as well, so I'm all done there for the time being. Back to Greyscale Mode.

This one is going to need a refactoring commit before the actual issue commit, to get all the necessary objects in createDataRow, so I can make the model trial. For example, foreground/background objects aren't in createDataRow.

I'm also very tempted to expand some of the other trial_data functions so they can be used for the non-top-level objects. (Able to go to trial_data['frames'] before looking for 'characters' instead of in trial_data.) Will this have any special concerns? Many of these functions are specific to trial_data instead of elements in trial_data, which has me on edge.

Oh, and how are we handling fields like action_parameters, which have many, many possible fields, most of which are never used? The model for that will be particular to the value of action_names.

EDIT: It occurs to me that we may need to put a function in the mode, which will determine the proper children objects at get/set time. I'll play around with this and see if it's viable.
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
Unas
Admin / Site programmer
Posts: 8850
Joined: Tue Jul 10, 2007 4:43 pm
Gender: Male
Spoken languages: Français, English, Español
Contact:

Re: Misc. Questions

Post by Unas »

The functions in the trial_data module come in two kinds :
- The generic ones that operate on any array, provided that its values are all objects with a unique id field. (eg. getIndexById, getById, getNewId, ...)
- The "shortcut" ones, fetching data from the top_level children of the trial_data global variable. (the corresponding getRowIndexById, getRowById, ...)
But those are merely using the generic ones behind the scenes, so I'm not sure what you mean about expanding the functions. When needing to work on non top level objects (and it's already the case for characters for example), I use the generic functions by passing the array directly.

Regarding action parameters, it simply does not have an object model. (Or rather, due to the fact that it's much more complex, having conditional fields and such, it has a separate object model with a much more complex structure : the global variable action_descriptions.)
It's not handled by the extension wrapper at all.

The correct approach here is for the frame row object model to simply contain the properties
- action_name = ""
- action_parameters = []
Oh, and also maybe update getExtensionWrapperFor to handle this properly, just making it so that if the objectModel received at this level is null or an empty array, then we just return the unwrapped original value.

I guess I should rather take care of putting in place the object model myself though, if I can find the time this weekend. To make sure it's done the way I mean it, since it's a rather big architecture change.
ImageImageImage
If knowledge can create problems, it is not through ignorance that we can solve them.
Si le savoir peut créer des problèmes, ce n'est pas l'ignorance qui les résoudra. ( Isaac Asimov )
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

Now that I'm trying to put into words the kinds of functions I was going to make, I see that they wouldn't have saved any time after all. My mistake.
Unas wrote:Oh, and also maybe update getExtensionWrapperFor to handle this properly, just making it so that if the objectModel received at this level is null or an empty array, then we just return the unwrapped original value.

I guess I should rather take care of putting in place the object model myself though, if I can find the time this weekend. To make sure it's done the way I mean it, since it's a rather big architecture change.
If you could do those changes, that would be fantastic!.

And out of curiosity, what timeline are you estimating for the next big release? If possible, I'd like to get the following commits done before then:
  • Greyscale mode - The big holdup here is the architecture change, and deciding when in the graphic loading process to apply the new function for viewport-wide effects. I'm thinking that this can occur even before we load the place.
  • Dialogue Colour Select - PR#22. The semicolons have been added, so this should just need your approval.
  • Remove Screen Preview Minieditor - Gamer2002 has done a good job explaining the problems with it here, and removing this would allow us to knock three other known issues. This one is simple enough that I can probably do it tonight!
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
Unas
Admin / Site programmer
Posts: 8850
Joined: Tue Jul 10, 2007 4:43 pm
Gender: Male
Spoken languages: Français, English, Español
Contact:

Re: Misc. Questions

Post by Unas »

FYI, my work to integrate the new object model is progressing well. This is what it's going to look like :
https://bitbucket.org/UnasZole/aao-game ... velop#diff

It's mostly done and working fine on my branch, I just want to do some small additional tweaks. Hopefully I'll have some time this week, but that's not guaranteed.
ImageImageImage
If knowledge can create problems, it is not through ignorance that we can solve them.
Si le savoir peut créer des problèmes, ce n'est pas l'ignorance qui les résoudra. ( Isaac Asimov )
User avatar
Enthalpy
Community Manager
Posts: 5169
Joined: Wed Jan 04, 2012 4:40 am
Gender: Male
Spoken languages: English, limited Spanish

Re: Misc. Questions

Post by Enthalpy »

What does 'default_value' in /includes/action_descriptions do, as on lines 404 and 408? A grep on 'default_value' shows no other code it relates to.
________________________________________________________________
I'm working on a bugfix for 106, that clicking on an examine without a set place leads to an unreactive black screen. However, I have two possible fixes, and as both of them have me uneasy, I'd like a second opinion. But first, the problem. We want the following behavior.

Click on 'Examine' Button -> Is there a place to examine? If yes, handle it normally. If not, go straight to the Default Conversation -> Finish Default Conversation -> Return to the main frame of the relevant dialogue

Relevant dialogue is the key phrase. In v6.1, there may be multiple relevant dialogues, and we don't know which is the right one until we actually open the dialogue. In other words, we don't know the redirect target until it's just about time for the redirect!

1. Override the GoTo

My approach has been to add a "Scene Descriptor" context field to the GoTo action. That gives us the information we need to find the relevant examination to compare end IDs against, and the relevant dialogue to go to the main frame of. The trouble is that trials made in/converted to v6 before this bug fix won't have "Scene Descriptor" in their context field, and because this is a hidden control frame, it's impossible to click on the action editor button, and add in context that way. No, we'll either need to do it manually (though I doubt there will be many cases of this) or decide this is v6.0.1, and v6 trials needs to be converted over to v6.0.1.

The obvious question is can this be fixed in a way that old trials suffering from this bug can still work?, and I don't think there is a way. Under the current structure, the data to tell the player "Hey, I'm a special GoTo, don't take me to where my parameter says I need to go! I know where I come from. You tell me where to go." Of course, this also means telling the player how to react to these "special GoTo" commands, which seems ugly!


We'll have to modify the v6 converter so that it actually does the conversion to the version where GoTo has a scene descriptor, version 6.0.1.

2. Redefine the GoTo

The second approach (which came to me as I was writing this post) doesn't complicate GoTo, but does involve the trial player editing the frames. In this paradigm, we make note of when a scene's dialogue changes. Whenever the dialogue changes, we go through all the examinations for this scene and set the closing control frame's GoTo target to the main frame or the examine frame, as appropriate.

This method doesn't require a change from v6 to v6.1, but the idea of changing frame data strikes me as something with all sorts of unintended consequences. If we can safely do this, this seems like the far better option.

EDIT: In hindsight, I favor option 1. Let's not "fix" the trial data needlessly. That said, I have no clue how modifying an action model can possibly work!
[D]isordered speech is not so much injury to the lips that give it forth, as to the disproportion and incoherence of things in themselves, so negligently expressed. ~ Ben Jonson
User avatar
mercurialSK
Posts: 297
Joined: Sat Jan 11, 2014 9:26 am
Spoken languages: English
Location: foolishly fooling like a foolish fool
Contact:

Re: Misc. Questions

Post by mercurialSK »

Is there a file for the forum skin? I couldn't find it...I just want to add a quick style to make the "full trial manager" button a bit more forgiving.

Code: Select all

#litetrialmanager div:hover:after {
    content: "";
    width: 100%;
    height: 3em;
    position: absolute;
}
Image

edit: fix
Last edited by mercurialSK on Sun Apr 17, 2016 12:01 pm, edited 1 time in total.
Image
Backlog: v6 Perceive generator, Apollo, everything else (My thread)
Someday, on AAO™: Chris Tenson: Ace Attorney & A Turnabout Called Justice (pt 2)
AceAttorneyMaster111
Posts: 468
Joined: Sat Sep 27, 2014 6:46 pm
Gender: Male
Spoken languages: English, français, un poco de español, עברית
Location: USA

Re: Misc. Questions

Post by AceAttorneyMaster111 »

IIRC, Unas keeps the forum codez on a separate repository or something like that.
Post Reply