I want to be able for the player to fold a mesh into what they want, meshes can cross each other as i’m looking for a simple solution.
hoping for a basic solution i can build off of
there isn’t anything about this online, just looking for ideas and suggestions
Should i use a 2d mesh? something about skeletal meshes?
a 3d mesh with physics and stuff is best, because i wanna make paper air planes that can fly. also the mesh not might be rectangular.
(The folding process i’m thinking of is: the player will plan out lines and how much of an angle the paper will fold across the line. all before the folding starts, and when the player decides to start folding, the paper will fold its self.)
2023-07-15 14-26-43.mkv (20.3 MB)
Made a crappy example but it works. code is pretty simple just slice a procedural mesh and rotate it using a timeline so it rotates smoothly. there are tutorials about slicing meshes if anyone is wondering
also thing about this is , you can only slice A mesh, so if you slice a mesh two times you will only get 3 meshes. because you can’t slice 2 meshes at the same time.(this will be a “feature” in my game, as i am too lazy to find a good solution)(just realized it might be really easy to implement but anyways)
to anybody that actually wants to try this: when you cut a procedural mesh, the center of that procedural mesh is the same as the mesh you cut, making the paper fold realisticly (around a line) is kinda hard, will need to use cross products and stuff
other un-important stuff:
rotating the mesh is kinda hard, and for reason it doesn’t work, rotation is kinda weird, this is a realistic origami simulator, but in java script and stuff : GitHub - amandaghassaei/OrigamiSimulator: Realtime WebGL origami simulator
it has a web version where you can play with
i will try to get this working in ue5, i’m not familiar with c++ in ue5, and i’m not sure how i’ll actually do this, but i think if i have a week, i probably will make this possible, also i can’t read java script but i’m sure things will be fine…right…