Australia
Joined: May 21, 2017
Post Count: 77
Status:
Offline
Building a bespoke staircase constructor plugin - need help
So I have decided to try my hand at making a plugin. Unfortunately I have never programmed in Java before and it is doing my head in. I have made a fair bit of headway, the code can be found on Project on Github.
I'm fairly sure I have chosen a difficult project to cut my teeth on, what I need now is assistance and advice.
Have I approached this correctly?
Should I pack my bags and go home?
What should I do from here?
Anyone that wants to help out with the rest of the code is welcome to contribute.
Romania
Joined: Apr 24, 2014
Post Count: 616
Status:
Offline
Re: Building a bespoke staircase constructor plugin - need help
For shore is a difficult project (at least for starting in any programming language).
Have I approached this correctly?
Depend of Your mind structure. From my side (inspired by Asimov): I know the final. For this I start with the end; what I want to happen in the end. Than I think what I need for this, who provide'it (usually the end user). I consider the user to be a most common person(over 65 old) who could use my soft; I keep this in mind and I try to make'it accordingly(specially the UI). So, You have to reconsider the approach.
Should I pack my bags and go home?
NO WAY BACK!!! Get Up and fight!
Anyone that wants to help out with the rest of the code is welcome to contribute.
Well not too much for the start: 1. I modify a little Your project. Could be find HERE 2. First observation on ApplicationPlugin.properties file: field class MUST be the same as package from class files 3. Second= in src directory You must have .java not .class You could see the differences in folder. Happy programming !
---------------------------------------- A computer program does what you tell it to do, not what you want it to do. Murphy's Law When all else fails, read the instructions. Murphy's Law If you don't like "AS IS", DIY. Dorin's law
Romania
Joined: Apr 24, 2014
Post Count: 616
Status:
Offline
Re: Building a bespoke staircase constructor plugin - need help
One more inspiration on this site . It do approximately what You want but You need to generate 3D objects not only flat. So, could be a very long way. I suggest You to start with more common stairs and than to add country specific restrictions. Also You must decide the approach: 1. Do an plugin, or 2. Do an separate application. While You don't need too much from SH3D You could choose the 2.
---------------------------------------- A computer program does what you tell it to do, not what you want it to do. Murphy's Law When all else fails, read the instructions. Murphy's Law If you don't like "AS IS", DIY. Dorin's law
Australia
Joined: May 21, 2017
Post Count: 77
Status:
Offline
Re: Building a bespoke staircase constructor plugin - need help
Nice find. I will see if there are things to adopt/steal.
I've been constructing a selection of parts to form the staircase and trying to work out how to get them into java. Manipulating them will be my next hurdle.
Australia
Joined: May 21, 2017
Post Count: 77
Status:
Offline
UI draft
I have been beating my head against Java UIs and now it hurts.
Importing 3D objects and displaying them is proving to be beyond me so far so I have put it aside to work on the initial set-up interface. So far they should make sense to most people.
From SH3D I mostly want the user to select the levels that will contain the staircase. I use this to determine the total rise which influences the number of steps required, how many landings, etc.
Basic step design is in prototype and looks like this
Step rise selection will be limited (eventually) to integer divisions of the total rise.
I also intend to give alternative nosing profiles beyond the default half-round.
If anyone can give guidance on importing, resizing, positioning and displaying objects in a j3d display canvas I am all ears.
Romania
Joined: Apr 24, 2014
Post Count: 616
Status:
Offline
Re: UI draft
1. It's a good training to exercise with UI, You will need it. 2. An other source of inspiration could be useful. Read it and You will find also some regulations (riser height, recommended outcome, angle of the stair, etc). 3.
If anyone can give guidance on importing, resizing, positioning and displaying objects in a j3d display canvas
I suggest for inspiration to study the code of: -Modify posture (SH3D) -Modify opening (SH3D) -Modify furniture (FurnitureLibraryEditor)
4. You will have also to generate 3D objects (read Export as new furniture & Shape generator plugins)
---------------------------------------- A computer program does what you tell it to do, not what you want it to do. Murphy's Law When all else fails, read the instructions. Murphy's Law If you don't like "AS IS", DIY. Dorin's law
What I need to know is: - Does Level Height include Floor Thickness? - Does Level Elevation measure to the bottom of the floor or the top of the floor?
I think that for the last step to come out even with the floor I might need to adjust my formula to;
UK
Joined: Jan 6, 2018
Post Count: 677
Status:
Offline
Re: Technical question about level heights
Hi Bill You may find some of the info Here helpful, it shows calculations for stairs 1 step down and with top tread level, plus many other things, i used it when calculating the stairs i have made. I cannot help with the java wizardry, sorry, but good luck Mike
No. Next level elevation=elevation+floor thickness+level height of previously level
---------------------------------------- A computer program does what you tell it to do, not what you want it to do. Murphy's Law When all else fails, read the instructions. Murphy's Law If you don't like "AS IS", DIY. Dorin's law