Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This question was closed Jul 22, 2021 at 12:03 PM by panzgfx for the following reason:

The question is answered, right answer was accepted

avatar image
0
Question by panzgfx · Jul 21, 2021 at 07:43 PM · randomrandom gen

Find bounds of random generation

Hi,

Basically, I'm trying to make a system that will adjust my astar pathfinding grid graph to match the bounds of a random room layout generation. I've figured out how to adjust the height and width of this grid graph during runtime, but I've been struggling to find a way how to adjust these values to match the height and width of this room generation.

For example, in the image below, the graph should adjust to fit the highest point, lowest point, farthest right, and farthest left points.

My makeshift solution has been to create a massive grid graph, to fit all kinds of generations (see in image 2), but this is very inefficient and has been causing some issues in my game. In short, I'm just really not sure how to go about tackling this issue, so any help would be massively appreciated.


Image 1: https://gyazo.com/d58fc362981e45a7c33ca8af9c5d4919


Image 2: https://gyazo.com/1850e17a34e1f954f79ac53d9920c871


[preview of external content removed for GDPR compliance as it was including 3rd party cookies]

Comment
Add comment · Show 5
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Long2904 · Jul 22, 2021 at 06:22 AM 1
Share

What is your current code so far? Tilemap has a cellBounds property that you can change, have you tried it yet?

avatar image rage_co · Jul 22, 2021 at 06:26 AM 0
Share

Im sorry i can't provide a solution but i can't help but notice that this game is actually BenBonk's slimekeep. If you indeed are ben bonk (which is very likely since the assets used in the game are not publicly available i guess), i think i can give you a welcome from the community here

avatar image rage_co · Jul 22, 2021 at 09:19 AM 0
Share

Just like @Long2904 said, we'd be able to help you if you can be a bit more detailed about what you want and what have you tried so far to achieve it (aka the script in this case)

avatar image panzgfx rage_co · Jul 22, 2021 at 12:03 PM 1
Share

Hey guys, I actually managed to figure it out using an alternative method. But I really appreciate the help :)

avatar image rage_co panzgfx · Jul 22, 2021 at 12:35 PM 0
Share

im glad you figured it out and appropriately closed the question. But, It'd be better if you could share a rough solution as an answer for future visitors, also all the best with the game.

0 Replies

  • Sort: 

Follow this Question

Answers Answers and Comments

131 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Generate the same 'random' number sequence from a seed 1 Answer

Random.Range doesnt work anymore 4 Answers

Somthing about my script i making unity hang if i set the room count any higher that 0 can't figure out what though ? 1 Answer

How can I make a Terraria Style game from sprites without using an enormous amount of gameobjects? 2 Answers

Random Generation Algorithm Error 3 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges