3D Library Adventure

mdotedot

  • *
  • Posts: 1532
Thanks for the feedback.

Yeah, once edited you click on Make Path to get the Blue line across your work. If the blue line can't be created it might conflict / intersect some other part. The idea is that the outline is a continuous shape / line so that it can become one mesh with vertices.
I use the Linear Extrusion method from the Library.
There are other means of accomplishing this but the shapes I got with this outline-method are very cost friendly.

Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

merrak

  • *
  • Posts: 2360
I seem to be having a lot of stability issues. If I create a simple maze and then click "create path", the "generate 3D" button completely disappears. I can still click on the space it was in, though, but then the screen goes completely blank. I'm not sure if this means I drew a maze in which the blue line can't be created at all. I tried a few different times, though.

Generating a random maze works perfectly.

mdotedot

  • *
  • Posts: 1532
So sorry that you seem to be having problems with this.
The generate 3D button disappears when there is no blue path.

I think you are trying to create a maze where the blue line can't be generated. Care to show me a screenshot? This happens to me sometimes as well. But usually clicking some paths away or add one or two solved it for my occasions.
Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

merrak

  • *
  • Posts: 2360
I'll see if I can reproduce it tomorrow. Don't be surprised if I just did something wrong :) I tried to make a maze that spelled out "Hi" (it's my own variant of a "Hello, World" program I've always used to test tile-based routines). I thought that maybe having two disconnected regions caused the problem, but I also tried drawing a straight line.

mdotedot

  • *
  • Posts: 1532
Thanks for this. I was able to reproduce.
The disconnected regions will not be created into one mesh, but it should at least do the H

A note : the routine assumes that your maze starts at 16 ( position 1,1 )
But even with that note I couldn't get a line on 16 to 91 work.

I will have to see what is going on.

Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

bonzero

  • Posts: 487
This is really impressive, even if this solution didn’t have the latest 3d features I think to have some 3d elements in a 2D game can be a very cool feature, very exciting stuff!

mdotedot

  • *
  • Posts: 1532
Thanks for the feedback BonZero.

Today I'm starting to create the actual extension as I  ( think I ) have now most of the sample code ready to make a first person maze walking game.

One of the things I will be looking at for other projects are  3D background(objects) for a 2D game. As well as a 2D based platformer that is visually a 3D representation.


Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

mdotedot

  • *
  • Posts: 1532
@Merrak: As far as I can tell your issue should be resolved. At least when you start at position 16 and keep your shapes connected.

Today I started to create the actual extension.

I was generating a bunch of meshes using the extension block with random mesh data.

Drawing meshes is as expensive as the Stencyl Actors. Here are some of my test-results:

Dropping to 30-40 FPS when hitting the number of meshes:
Flash in VM   100
HTML5 in VM   50
Windows in VM200
Mac OS     200
iOS Simulator   40
Android(nexus 6)   80

Note: I was using virtual machines and a MacBook from 2011 so newer (real) hardware might do it better.
Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.


squeeb

  • Posts: 1492
One of the things I will be looking at for other projects are  3D background(objects) for a 2D game. As well as a 2D based platformer that is visually a 3D representation.
!   Like a 2.5 d?
I'd love a 3d background scene or 3d objects in a  2d game!
If i had money.. id fund you both @ M.E.  and Merrak ... well... Maybe one day I could! Keep up the great work

mdotedot

  • *
  • Posts: 1532
Thank you Squeeb for your nice words.

So far I only managed to get 3D Objects to appear BEHIND Stencyl objects. So a 3D background should be feasible.

There is one major issue I have with combining a 3D scene with Stencyl: Scene background in Stencyl should be set to 'no color'.
Once you have one scene in Stencyl with a (gradient) background it will  never show the 3D scene again.
Hopefully one day I find a way to workaround this.

I've already made a really simple 3D Scene based on some Stencyl actors with Box2D physics on them so I want to experiment with this further to see if I can make 3D objects match all the physics engine stuff that Stencyl has. Rotation, Position, Scale should be feasible, but I'm not sure on the mass/airflow effects. At least this gives some 3D effect but on a fixed z-axis.

We will see what comes out of these experiments!


Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

mdotedot

  • *
  • Posts: 1532

Last week I’ve worked on getting a real 3D Maze Game going.

Creating extension blocks along the way.



I need a mathmagician to convert 2d coordinates to 3d and 3d coordinates to 2d coordinates




This is what I did with the mazegenerator data. I’ve created dynamic tiles based on the generated data.

The ‘follow actor with mouse’ behavior was set on the player and this is how it looks :






In game effect:



But once I tilted the camera the Z-coordinate was misplaced and it messed up!





And:







For someone who is more familiar with 3D programming this might be an extremely easy task but I’ve yet to find the magic code.



If anyone can point me in the right direction I will be thankfull! I've been messing with this a couple of days now :(

Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

merrak

  • *
  • Posts: 2360
I assume you are trying to project the white ball from 2D Stencyl scene coordinates to 3D maze coordinates, then project to screen coordinates. Is that right?

mdotedot

  • *
  • Posts: 1532
Thanks for trying to help merrak : I appreciate it!



But :                    I was sooo stupid!

  • 3D Maze had a scale on it (different from the player+stencyl tileset)
  • Camera adjusted to 3D Maze rather than player
  • Actor in Stencyl was not 32x32 , which I assumed it was !
  • Too focused on follow mouse behavior



I’m still going to find out how to get a better mouse behavior, but it was too confusing for so early on in the 3D game development!!!





Click on the image to play



   



Move with the arrow keys



You can adjust the properties of the objects. Use the mouse to click on < and >
Hanging out in the Chat:  http://www.stencyl.com/chat/

Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

NickamonPoppytail

  • *
  • Posts: 1080
This looks complicated. Nice work!
Upcoming Projects
Poppytail 5 and Pixeltail: Fifth and sixth main instalments in Poppytail series. A Game About Trimming Hedges: Final Version: An updated version of the original AGATH; also canon to the Poppytail series. Easter Fun 2: A sequel to the original Easter Fun. One Million: Last-one-standing style small project; also canon to the Poppytail series.. The Poppytales: Hand-drawn spin-off bullet-hell RPG using characters from all my other book and game projects. Not canon to the Poppytail series.