-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adjust issue when save #72
Comments
When current running pose name is changed, the core initiates a reset. This clears hudId var and the hud is no longer responsive. The only reason for the reset is to get the menu up to date which is being done in state_entry of the core. As noted in the core script, this is also being handled in the menu script. Removed this code from the state_entry of the core and also removed the reset commands in the changed event of the core. This fixes the issue and also cleans up the code. I will create a branch from the Grouping branch with this and other changes. |
I find that the core needs to run this on reset or the changed event does not work after the slave is reset. No new sitter is allowed. |
Also the slave does not have a slots list after reset and does not get it until a seatupdate is done. There is no harm in this action because as soon as we have a new sitter, the slave gets the update. |
You removed a few resets inside the core. That means that the DEFAULT NC is not running after changing a script. I don't now if that is bad for every day usage, but if you develop a script you have to reset the core after you saved your script to get for example the global options or a new Slots list. |
I removed these resets because the adminhud stops working any time the The worst problem I observed was when the slave is reset, it would not have
|
Well, I don't think that removing the resets is a good idea. As an example, let us assume a setup like this: NC: DEFAULT:default NC: BTN:1 The old code resets the core if changing the BTN:1 card, with the new code I guess nothing will happen ... Let us first split the problem into to separate problems. As Emilie Muggins said:
I also don't see it as a problem
Well that is a problem. But maybe we should not try to fix it by removing the resets but by improving the HUD protocol to allow a reconnect after a reset. |
On the other side of the coin, if we do everything a reset would do in the changed event without destroying the current state of the system, we accomplish protecting the HUD protocol and maintain the slots list to keep all sitters in their current seats... etc. This side of the coin says do what needs to be done when a card is modified or added rather than discard everything and rebuild. |
Well .. that may also work. Perhaps we should make a little list of things that could be changed inside the prims inventory and what should happen then. We can add, delete and modify each possible inventory item. If the added, deleted and modified inventory item is a NC maybe we have to determine its relevance to nPose. so we have: add a DEFAULT NC and of coure the script itself don't know what is added/edited/modified |
Of course you're right about the script not knowing but I believe all of these things fall under changed inventory. It would be nice to act smart and only handle the situations which pertain to the moment in the script but we are really limited as to how much code we can write in SL. All we can do when inventory changes is to handle the situation as if it were important at the moment without destroying the moment (if possible). |
The list above was to think about what could happen inside the inventory. As you said: we can not write code for each different event (because of the memory and because we don't know what exacly happens).
Can you explain it a little more? Maybe I'm thinking in a wrog direction? |
I think we must rebuild the menu any time a DEFAULT, SET, or BTN card is I think it probably doesn't matter if we rebuild the menu in the case where If this script changes, it will be reset. Well anyway this is my train of thought. On Jul 15, 2016 7:41 AM, "LeonaMorro" notifications@github.com wrote:
|
yes. and because we don't know if a DEFAULT, SET, or BTN card is changed, modified, or deleted. we have to rebuild it on every inventory change. But we are not talking about the menu, we are talking about the core. What if we changed for example a global option (or anything like it) inside the DEFAULT card? Then the DEFAULT card must be executed to let the core itself and/or any the other scripts know that it is changed. ->the "current state" is destroyed The longer I think about it the bigger my concerns. If we miss only one part ... |
As for the core we check if the current card still exists and if it has In any other case, is it wrong to do nothing until a menu selection tells Which is worse; reset when we know it is wrong in some cases, or do nothing This is the dilemma. The reset is causing a problem and removing the reset If options change in the current card, the changes would/ should be picked On Jul 15, 2016 9:36 AM, "LeonaMorro" notifications@github.com wrote:
|
Sorry about that last post. My smart phone did something not so smart and that post ended up scrambled it seems. It gave me a bit of time to look at the core and reflect on this situation (My head sometimes casts too large of a shadow). When I look at the state_entry() function to see what happens on reset besides clearing the history of variables associated with a clean script, I see 3 things happening:
Items 1 and 2 really have no effect on the system or situation. Item 3 however has a some possibilities to do some things either wanted or unwanted.
Global options might be the only good reason to re-read the default card but only if the options exist in that card. We do have the ability to put the global options into any card or even have different options for different situations in other cards. Removing a card which has set some global options is going to require all scripts reset to remove them completely from nPose, re-reading the default card or finding a new default card and running it will not reset the global options other than the ONE global option stored in the core (to get a menu when new sitter sits). Also, yes the core, the menu, and the slave do reset when there is a change of ownership. All this and I do not find one good solid valid reason to reset the core when inventory changes. |
After sleeping and reread the whole stuff ... let me try to make a summary:
I guess we exchanged almost all Pros and Cons and I see that not reseting will solve the problem with the HUD without great effort. Nevertheless I'm still a little concerned, but not enough to definitely say that not resetting is a no-go. Additionally my concerns seems to be more like a gut feeling, because I can't add any futher sound arguments. Maybe I should wipe them away. |
Improved in nPose V3.00 and in nPose V3.10 |
Emilie Muggins: each time you change something that implies rebuilding the menu like renaming a set nc or adding new ones the av revert back to the default nc which is not a problem but it also kills the hud so you have to detach reattach it
The text was updated successfully, but these errors were encountered: