-
-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Storing array #90
Comments
You can pass an integer as a second argument into The number you use with your typed array definition controls how large the array is for each entity. With a size of 1 it's basically pointless compared to a single ui8 value. If it's meant to index the tiles on your map, then it needs to be as big as the map's total number of tiles. |
This is due to a resizing bug on the current release. it should be fixed on |
Can't seem to figure out how to store an array of ui8. I have a component for FieldOfView which changes everytime the player moves. The visibleTiles just hold the idx [
(y as usize * self.width as usize) + x as usize
] to the relative tiles that are currently visibleAfter this definition, I get unknown as the type
![CleanShot 2022-07-02 at 14 58 08@2x](https://user-images.githubusercontent.com/9278174/177014654-950c6d28-6328-477d-bbb2-40c3f8b7e20b.png)
Im probably missing something really simple. Or if there is a better way to store visible tiles let me know
The text was updated successfully, but these errors were encountered: