aalavandhaann / blueprint-js

The Javascript es6 version of the original furnishup/blueprint3d. Need some royalty free low poly models for the inventory. Can someone help me with this?
MIT License
504 stars 158 forks source link

total wall and floor area #14

Closed micreales closed 5 years ago

micreales commented 5 years ago

Hi, is there a function/module in this project where I can get the total floor area and total wall area of floorplan? Thanks

aalavandhaann commented 5 years ago

Yes this is possible. In the models folder you have the necessary functions to achieve this

micreales commented 5 years ago

I tried to find but still no luck, what is the function there?

aalavandhaann commented 5 years ago

See https://github.com/aalavandhaann/blueprint-js/blob/master/src/scripts/model/floorplan.js

It has the function to get all the rooms. Here reach room is made of corners. Now the area of the room needs to calculated based on the polygon shape formed by the corners.

Regards,

0K

micreales commented 5 years ago

Wow thanks for this, it really helps. After getting the area of polygon would that be the floor total? Im sorry im not familiar of getting area or something, i just need on my task. Thanks

On Fri, Jan 25, 2019, 8:22 PM #0K Srinivasan Ramachandran < notifications@github.com wrote:

See https://github.com/aalavandhaann/blueprint-js/blob/master/src/scripts/model/floorplan.js

It has the function to get all the rooms. Here reach room is made of corners. Now the area of the room needs to calculated based on the polygon shape formed by the corners.

Regards,

0K

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/aalavandhaann/blueprint-js/issues/14#issuecomment-457556644, or mute the thread https://github.com/notifications/unsubscribe-auth/AgJ8DhfhtHjhcTf66ow2EqIjzaHZLIYjks5vGvb4gaJpZM4aHlS3 .

micreales commented 5 years ago

Hi , @aalavandhaann , I have a question, can I have the same way dragging or moving the floor items same the behaviour in wall items ?

aalavandhaann commented 5 years ago

Yes, anything that extends wallflooritem class will have this behavior. There should be items in the inventory to demonstrate this behavior

micreales commented 5 years ago

Hi, I tried to check the blueprint script, not sure how can I found the implementation of (when you drag or positioning the window or door) the wall becomes black, and the sensitivity is much smooth than positioning a rug.

aalavandhaann commented 5 years ago

Which script did you check? Check link

micreales commented 5 years ago

Hi , do you have any idea on how can I retain the items even if I changes the room size ? (e.g the door is the corner left side, if I tried to adjust the floor plan and increase the width of wall, the door will still be there at the same place) ?

Thank you.

On Fri, Feb 8, 2019 at 9:23 PM #0K Srinivasan Ramachandran < notifications@github.com> wrote:

Closed #14 https://github.com/aalavandhaann/blueprint-js/issues/14.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/aalavandhaann/blueprint-js/issues/14#event-2127057166, or mute the thread https://github.com/notifications/unsubscribe-auth/AgJ8DvFpPNg09FqSWHKckVyFZou8i8IQks5vLXo6gaJpZM4aHlS3 .

micreales commented 5 years ago

Hi, do you have any idea on rotating rug, (not allowed to penetrate or stick agains the wall) ? Thanks

On Tue, Feb 12, 2019 at 6:06 PM Emerlito Reales micreales04@gmail.com wrote:

Hi , do you have any idea on how can I retain the items even if I changes the room size ? (e.g the door is the corner left side, if I tried to adjust the floor plan and increase the width of wall, the door will still be there at the same place) ?

Thank you.

On Fri, Feb 8, 2019 at 9:23 PM #0K Srinivasan Ramachandran < notifications@github.com> wrote:

Closed #14 https://github.com/aalavandhaann/blueprint-js/issues/14.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/aalavandhaann/blueprint-js/issues/14#event-2127057166, or mute the thread https://github.com/notifications/unsubscribe-auth/AgJ8DvFpPNg09FqSWHKckVyFZou8i8IQks5vLXo6gaJpZM4aHlS3 .