Yeah, that worked, and not having to explode my group fixed a lot of problems. Thank you!
Latest posts made by lothcat
-
RE: Deleting group.copy?
-
RE: Deleting group.copy?
That may just work. And I figured out why I can't erase the group.copy - because I exploded it. Sometimes I feel dumb.
-
RE: Deleting group.copy?
@thomthom said:
What do you mean by this? "Look at the faces"? I'm wondering why you are making seemingly temp groups to inspect something.
I have attributes attached to the faces that I need to read, but I also have attributes attached to the group. If I don't explode the group, I can't get to the attributes in the face, but if I do explode the group, I lose the group attributes.
Probably not the best way to do it, but it works.
And thank you for the help!
-
Deleting group.copy?
I am having a hard time figuring out how to delete a group. I'm making a copy of a group to explode it and look at the faces, because I want to keep the original group intact, and then when I'm done with the copy, I want to get rid of it.
Here's my code:
if entity.typename == "Group" #UI.messagebox "Group!" copy_group = entity.copy status = copy_group.explode facecounter(status)
I tried using entities.erase_entities copy_group where entities = Sketchup.active_model.active_entities, but that didn't work, so now I'm wondering if there's a better way.
-
RE: Weirdest loading bug ever?
Thank you so much! It's working now and I'm not having that weird loading bug!
Also, thank you for being patient with me. This was a real learning experience.
-
RE: Weirdest loading bug ever?
I'm still using seven because I want to make sure that everyone in the company can use it, but if I have to force people to upgrade, so be it.
Turning off the RELDIR/ABSDIR calls seems to fix it for now.
-
RE: Weirdest loading bug ever?
You're right, I'm leaning on you a lot - it's because you're introducing a ton of stuff here that I've never used, and I wasn't even sure where to begin debugging. I'm still new to this.
I tried modifying your code to my module, but when it didn't work, I tried making the snippets exactly how you wrote them.
I'm putting the ext file in the plugin folder, and the others under lothcat/widget, then starting up sketchup rather than using load. The error is what appears on startup. I thought maybe it was loading the files in the @@plugin statement, so I moved that further down... and that didn't work either.
I can fiddle with it on my own for a while to try to find the problem.
Thank you so much for your help!
-
RE: Weirdest loading bug ever?
I'm trying to use this loader, but I keep getting errors. Specifically:
Error Loading File F:/Program Files (x86)/Google/Google SketchUp 7/Plugins/lothcat/widget/widget.rb
uninitialized constant Lothcat::Widget::RBSFILEError Loading File F:/Program Files (x86)/Google/Google SketchUp 7/Plugins/lothcat/widget/widget_loader.rb
uninitialized constant Lothcat::Widget::RBSFILEError Loading File lothcat_widget_ext.rb
uninitialized constant Lothcat::Widget::RBSFILEWhen I changed the names, I still get an uninitialized constant error.
-
RE: Weirdest loading bug ever?
Thanks for all your help! But I'm not sure I understand - is it better to have the loading script inside the widget folder instead of the plugin folder?
My current loading script is inside the plugin folder, and goes something like this:
Sketchup.load('LothCatWidget/widget') WIDGET_tool = WIDGETmaker.new plugins = "LothCatWidget/" imgdir = plugins # create toolbar tb = UI;;Toolbar.new("LothCatWidget Toolbar") # Button 1 cmd = UI;;Command.new("Widget") { Sketchup.active_model.select_tool WIDGET_tool } cmd.large_icon = cmd.small_icon = File.join(imgdir, "WIDGET.png") cmd.status_bar_text = cmd.tooltip = "Widget" tb.add_item cmd
Would it be better to have this script inside the folder? Do I need to separate out the 'load' command from the toolbar script? And are you saying that it's the fact that I'm using Sketchup.load instead of Sketchup.require that's causing my weird bug?
-
Weirdest loading bug ever?
This is such a strange issue, I don't even know how to describe it properly.
I am developing a plugin for distribution, and therefore I am using scrambled files. I do most of my coding/debugging with the unscrambled files and only load the scrambled files to make sure they work before I send them to my boss. We're just now entering the testing phase.
I only noticed I had an issue when I realized one of my messageboxes was wrong while I was using the scrambled files. It was a silly bug - it had a blank where it needed a dropdown. I fixed it, scrambled it, restarted sketchup - and the blank was still there. So I reworked that messagebox and reordered the inputs, scrambled, reloaded - and it was still the same (wrong) messagebox from before. When I loaded the unscrambled version, the messagebox was fixed, but as soon as I tried to load a scrambled version it was wrong again.
I thought it might be the scrambler, that maybe it was just outputting the wrong file, but when I added or removed comments the scrambled file changed size. I thought it might be a caching issue, so I shut down my computer - but it was still there the next day.
So then, on a whim, I renamed the folder I was loading the plugin from. The images were gone, but my plugin still popped up and worked! The wrong messagebox version, of course.
I was able to load my plugin on a borrowed laptop just to make sure the scrambled files are actually correct, but now I'm worried that I'll be giving out new versions to my testers and this weird glitch is going to keep the older version there, especially since this glitch has appeared on my boss's computer as well.
I am completely flabbergasted, I have no idea how this is even possible. I am using Sketchup.load(extension_name) and Sketchup version 7 running on Windows 7, and my boss has Sketchup 7 running on Windows XP.
Has anybody else had this issue? Is there some sort of unload or reload command that I need to include to make sure Sketchup is using the correct files? Is this a known bug they fixed with Sketchup 8? Or am I the only one with this problem?