Comments (13)
why is this so frickin hard
from ursina.
You should look up uv mapping. Here's an explanation: https://www.youtube.com/watch?v=scPSP_U858k
from ursina.
from ursina.
The uvs are part of the model, so you don't have to do anything, just set the texture you want (texture='file_name').
The easiest way to make a cube like that would be to replace the model with a custom one that's unwrapped how you want it. While it's possible to use 6 quads and 6 images to make one cube, it a bad idea since it's ~6 times less performant.
If you want to change the uvs in ursina without using a 3d program, you can modify/set model.uvs and then call model.generate() to update it.
from ursina.
Thank you for the explanation! I didn't know it was that simple.
from ursina.
Again, I've got a question. I've right now used the Blender default cube and scaled it by 0.5 along all axes (because I've seen that it's 2x2x2 by default). I switched to Edit Mode and checked the UV map. It was fine but just for the sake of correctness I pressed "u > UV Unwrap".
I had 6 tiles, so I combined them with ImageMagick into a single quadratic 512x512 cubemap so that it fits the Blender unwrapping.
As you can see in the image, I had to rotate each side by 90 degrees for them to show up properly.
Now it's looking good but not entirely perfect. I can see slim white lines on the edges of my cube - in my game as well as in Blender when applying the cubemap texture.
However, I can't see the lines in my cubemap.png . Do you know if I'm doing anything wrong?
from ursina.
I believe those are uv seams. The common way to solve that is to extend the edges in the texture so there's less white space around the shape.
For pixel graphics you can just disable the bilinear filtering with Texture.default_filtering = None
from ursina.
how do i make my own textures using blender
and i need it to be a png uv map
btw pokepetter if u see this u might know me as
"THE_godof_death" from your discord server :)
from ursina.
Hi.
Can you please explain how I can use collision!? in 2D mode between two objects, it looks very complicated!
Thanks a lot.
from ursina.
The way I check for collisions is first:
- adding the box collider to an Entity: your_model=Entity(model='quad',color=color.white,scale=(1,1),position=(0,0),collider='box')
-then doing the same thing with another object - and then checking for a collision in the main loop:
def update():
hit_info=your_model.intersects()
if hit_info.hit:
#Do whatever you want
from ursina.
You should look up uv mapping. Here's an explanation: https://www.youtube.com/watch?v=scPSP_U858k
what software do you recommend because i have had no luck in finding any good free ones.
from ursina.
Blender is probably the best free one, even it's very hard to use.
from ursina.
Blender is probably the best free one, even it's very hard to use.
I made that comment a while ago. since then, I have already learned blender. thanks though.
from ursina.
Related Issues (20)
- I tried to merge all cubes in Mesh() function, but it didnt worked for me... HOT 1
- The discord link on reddit is down. HOT 1
- ERROR: Cannot install ursina==0.2, ursina==0.3..........ursina==6.1.1 and ursina==6.1.2 because these package versions have conflicting dependencies. HOT 2
- macOS missing dependency: ModuleNotFoundError: No module named 'screeninfo' HOT 3
- I used 'parent=terrain' and it didnt still worked for me for increase the performance: HOT 1
- Typo on documentation Entity Basics - Other Magic Functions HOT 2
- InputField should have a "wrap text" option
- Ursina cannot open monitor under Docker
- Graphics issues when converting to .exe HOT 2
- Ursina Build too little info HOT 1
- i am getting this error while adding the code snippet for inventory to my game. can someone explain it? HOT 4
- Loading issue for settings.py HOT 3
- Using more than one boxcast in a single update breaks some of the boxcasts. HOT 2
- Feature - allow the Audio class to allow .mp3 files. HOT 1
- Remove all entities HOT 1
- RTL language support (Persian/Farsi)
- Can't use pyinstaller to ursina HOT 4
- how to load multi textures for one model HOT 1
- Cannot build to exe because of module not found error HOT 2
- how to optimize gaem
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ursina.