An Alternative Entities Editor


#41

Why did you not named the script something like CADedit.js ?
Because i have sometimes 2x edit.js in the list.

No vertical line ? or do i not see it ?

Yes, going to use your edit.js more. well pretty forced to use it. because the hifi one have lot’s of problems right now. Seems yours is showing the filepath normally :slight_smile: It’s silly, but missing the button on screen is really strange. it’s so easy and quick that way to open and close it. But after short time you get used to it.

You know what would be nice, if the model list is always visible. of optional to pop open. now it’s always many times switching between first tab and last tab etc.

Why is ctrl-e, to close the window. not working when the edit window is active ?

It seems to work prett good for me now ! with reading. (or i have a good eye day)


#42

Thanks fro your comments, @Richardus.Raymaker .

  • To distinguish between the two edit.js programs in the Running Scripts window, you can click on one so that it is highlighted and the script path is shown on a second line.
  • Correct, no vertical separators between the columns in the entities list.
  • I’ve made a note of the idea of having a separate window or similar for the entities list so that it can be always visible, thanks.
  • Good point about Ctrl-E not closing the editor window if it has focus. Bug noted.
    My eyes are better some days than others, too : )

#43

Interresting problem. Did add debug print in my script that print much lines on the console and because a bug in my program not stopping.

And now CTRL-E is not working, just wanted to report it. Not sure aht or how. Or if it’s a bug.

[05/20 15:32:04] [WARNING] QAction::eventFilter: Ambiguous shortcut overload: Ctrl+E

Stopped the script spam, it still not woirked. Done relog. It’s still broken
Chgecked running scripts, for soem reason your script where running more times. strange because i moved it into my defaultscript because the lopad script from url always last iut with restart. It mabye returned today spontanic. After relog it seems to work again.

Just clicked on empty area in the entities tab.

[05/20 15:41:20] [DEBUG] JS console message at line 11 from “http://ctrlaltstudio.com/downloads/hifi/scripts/html/edit.js” - “TypeError: null is not an object (evaluating ‘t.nodeName’)”

The error happens when you click the blank area below the entities list.


#44

Release 0.1.3-51:

  • Add a search filter to the entities list.
    Search is conducted over the entity type, name, and model filename.
    Multiple terms are ANDed together, i.e., if you search for “tree fbx” only entities that have both “tree” and “fbx” somehere within their type, name, and filename strings are displayed.
    Search is case-insensitive.
  • Reduce font contrast a little.
  • Fix Ctrl-E not closing editor window when it has focus.
  • Fix program log error if click in blank portion of entities list.

#45

One question, i cannot figure out how to rezz entity cube with your edit tool. The buttons you expect it wouild rezz. It’s not doing anything.

Is it mabye also some idea to add Distance to the entities list ? so you can see how far the entities is away from you.

Other request, you know it from Secondlife. Is it possible todo vector copy in High Fidelity ? so we can copy x,y,z in one stop ? This is for rotation and position usefull.


#46

@Richardus.Raymaker To add a box entity:

  • Click the “Box+” button. Notice how it is highlighted and a green grid is displayed at foot level.
  • Click on the grid at the position that you’d like the box entity added.

I’ve added your vote for doing vector copy/paste. Not implemented at present but is on the to-do list.

Also, thanks for the suggestion on adding a “distance” column to the entities list. Noted.


#47

@ctrlaltdavid

Intressting one, because i use your tool. i removd the orginal one from my defaults script. But that also means , examples get useless.

After loading edit.js i can load the skyzone.

Anothe rthing i noticed, if you select the entity from the list, you cannot resize it until you click it inworld.


#48

@Richardus.Raymaker Wow, that’s an unexpected coupling between examples.js and HiFi’s edit.js script! I’ll have to investigate.

Regarding the behaviour you’re seeing after selecting an entity item in in the list: you don’t actually have to click on the entity in-world; you just need to give the Interface window focus (e.g., click on its title) for edit.js to recognize Ctrl+Shift key presses that activate the stretch handles. (Note that the “move” handles work without needing to explicitly give the Interface window focus.) This is kind of expected behaviour but could be improved upon - I’ll have a look. Thanks!


#49

you just need to give the Interface window focus (e.g., click on its title) for edit.js

Confirmed, not sure why that one escaped me.


#50

@ctrlaltdavid I’ve seen an issue where when editing an entity with your script, you must first interact with it before Ctrl or Shift Ctrl will work. As example: editing a box entity, when first selected holding down the (ctrl) or (shift)(ctrl) keys do not change the indicators to Rotate Mode or Resize Mode. But after clicking on one of the Axes move balls (Red, Green, or Blue), they work.

I hope this is fixable.

Also, just wondering if you or anyone else has tried your edit.js and inspect.js with Vive hand controllers. I am having some problems with the hand controllers and wonders if there is an issue. Tomorrow I will try using them with the default edit and inspect to see if it makes a difference.


#51

@Twa_Hinkle I can’t reproduce the problem of Ctrl / Ctrl+Shift not changing the manipulator handles to rotate or scale. Unless you mean select the entity in the entities list then try Ctrl / Ctrl+Shift, and yes Ctrl / Ctrl+Shift don’t work until focus is changed from the entities editor window to the Interface window. (One way of changing focus is clicking on the entity or the translation handles; another is just to click Interface’s titlebar.) Which is what Richardus found to be a problem, too. It is fixable and is on my list to do so : )

I haven’t tried editing or inspecting with Vive hand controllers 'cos I don’t have a Vive. Nor any other controllers because I need a new computer. My script’s entities editor window won’t display in HMD view because it’s intentionally a WebWindow so that it can be displayed outside the Interface window, e.g., on a second monitor. It could be made to switch to use a QmlWebWindow when in HMD view, or better still QmlWebWindow could be made able to be moved “off screen”. But for now it’s aimed at the desktop use case while I add further features. But I’m really interesting to hear how you get on editing and inspecting in the Vive!


#52

Usability tweak. I’m forever turning the filter distance up, it defaults at 10, if prefer it to start massive then reduce it if I need.
always annoys me but I never thought to tell anyone :smiley:

oh id like an lock/unlock everything check box at the top of the entities list

i would also like to select a bunch of lights and change their colour all at the same time, which is I put in 50 street lights and smokey said can you make them less yellow :smiley:


#53

Horses.
I was forever turning the draw distance down in the system edit, with Daves I dont have to :slight_smile: I have hundreds of objects within 100 mtrs, and I’m usually working on stuff I am standing near. -1
Courses.

I like the idea of global lock/unlock. +1

This is a pony wish, because “lights” is to broad a term, it will change all your nice red and blue lights not just your streetlights. You need a specialist script like this.

// find all lights within given radius and change the color.
// Adrian 22 May 2016
// blameJudas.js
var newColor = {red: 1, green: 1, blue: 255};
var name = "Streetlight";
var ids = Entities.findEntities(MyAvatar.position, 100.0)
print("hello, working here.");
print("length = " + ids.length);  
for( i = 0; i < ids.length; i++){ 
    var id = ids[i];   
    var properties = Entities.getEntityProperties(id);
   if(properties.type == "Light" ) {
        print("found one"); 
        if (properties.name == name){ 
            print("got one");
            Entities.editEntity(id, {color: newColor});
        }      
    }   
}
Script.stop();

This works. Change the var newColor to whatever you need, change the var name to whatever the name of your lights are. Or name all your lights Streetlight, for future handling.
For 50 unnamed lights you might be best locking all other lights and running a blanket edit.
Comment out the lines filtering by name to blanket edit all the lights within range.

change these lines

          if (properties.name == "Streetlight"){ 
                print("got one");
                Entities.editEntity(id, {color: newColor});
            }      
        }   

to this

     //     if (properties.name == "Streetlight"){ 
                print("got one");
                Entities.editEntity(id, {color: newColor});
     //       }      
        }

#54

Bad idea, if you have scripted objects that moce as example n click. When you lock it. zThe stop working. Made bug report but the say that is how it need to work,need to see if some more info is posted. Because i still want to lock dntity but it need to be moveable with the script inside it.

I think locking items from the entities list would be good, and see wich one is locked and wich one not.

Mabye if it’s still open others can comment on it or we need forum topic.

Also i like the 10 meter distance more, less searching.


#55

That’s a useful script, i was trying to open the domain file and do a find replace then re zip the thing which totally failed largely due to incompetence thanksss :smiley:


#56

@Judas @Adrian For search distance, what say I make the editor remember the latest value so that it resumes with that value when you load the editor next time?


#57

works for me oh unless u can make @Adrians default to what i have mine set to , to make his head explode :smiley:


#58


#59

Can you detect when a domain is changed ?
And if it’s changed do automatic entity list refresh ?

Why, i keep the editor open when teleporting to sandvbox and back.
But the bad side effect i think is that i see wrong info in the entities list ?

I need to keep eye on why i get sometimes 4 skyboxes in the entities list, and only one is from me.

Not sure if it’s High Fidelity bug or Edit bug.


#60

@Richardus.Raymaker The entities list already refreshes when you change domain: have the list displaying; change domain and the list is erased and the populated with entities from the new domain.

For your “4 skyboxes” problem: does clicking the “Refresh” button make the unknown ones go away; does restarting the edit script still show them; does HiFi’s edit.js show the same thing.