Vousk-prod. Posted October 11, 2015 Share Posted October 11, 2015 Ah ah, you're right they had normals inversions problems. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 11, 2015 Share Posted October 11, 2015 Your maze looks a..mazing Wingnut 1 Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 11, 2015 Author Share Posted October 11, 2015 Yeah! Found it!! Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 15, 2015 Author Share Posted October 15, 2015 Bump! How is everyone? Getting lost in mazes? 15 days to go! jerome 1 Quote Link to comment Share on other sites More sharing options...
Wingnut Posted October 15, 2015 Share Posted October 15, 2015 Wanna see a GREAT maze that Deltakosh made? https://github.com/BabylonJS/Babylon.js/blob/master/src/Mesh/babylon.mesh.js#L1802 Yep, mesh.CreateDecal! It takes a serious explorer to navigate THAT puppy RaananW 1 Quote Link to comment Share on other sites More sharing options...
jerome Posted October 15, 2015 Share Posted October 15, 2015 Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted October 15, 2015 Share Posted October 15, 2015 Wanna see a GREAT maze that Deltakosh made? https://github.com/BabylonJS/Babylon.js/blob/master/src/Mesh/babylon.mesh.js#L1802 Yep, mesh.CreateDecal! It takes a serious explorer to navigate THAT puppy Hey, one can implement this function in its maze, to help people finding the way ! "pshiit" a decal on the wall, and you'll see if you've been there already Wingnut 1 Quote Link to comment Share on other sites More sharing options...
Wingnut Posted October 15, 2015 Share Posted October 15, 2015 I think mirrors could be trouble. Then, maybe you find out... that the character you are playing... is actually a section of wall... which has come alive and is trying to find a way to escape all his welded-in-place brethren. Wow. As you walk up to a wall mirror... it appears you are walking-up to a brick wall, but it was really YOU walking-up to the mirror. Or something like that. Or not. Quote Link to comment Share on other sites More sharing options...
iiceman Posted October 15, 2015 Share Posted October 15, 2015 Still on vacation but I made good progress before I left and vacation is almost over, so almost ready to continue. The only Problem is that I am not totally sure what I want... So many ideas though Quote Link to comment Share on other sites More sharing options...
JohnK Posted October 15, 2015 Share Posted October 15, 2015 Just another hour and I'll have it finished. Mmmmmmmmm I think I said that to myself about 40 hours ago. jerome and GameMonetize 2 Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 15, 2015 Author Share Posted October 15, 2015 Awesome! I'm waiting for your PMs :-)oh, and I think the decals function is more than a maze. It's a riddle. If you solve it you get to go to another level and find out if Paul really is dead. But no one made it so far. Wingnut 1 Quote Link to comment Share on other sites More sharing options...
iiceman Posted October 19, 2015 Share Posted October 19, 2015 My maze is already so cool, I think I have to show it even before the end of October I still have two bugs that keep... bugging me (get it? )... not sure if I should try to recreate them in the playground without showing too much of my maze or if I should just post the whole maze so you can see the problems... :-/ RaananW 1 Quote Link to comment Share on other sites More sharing options...
JohnK Posted October 19, 2015 Share Posted October 19, 2015 Has anything changed with the playground in the last 12 hours? In my maze I had a tube created with the original method and it appeared OK last night but this morning the tube is no longer shown. My code still works locally with the BJS2.2 version I had downloaded. Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 19, 2015 Author Share Posted October 19, 2015 @Jaskar - First PM received!! Awesome!! @John - Can you create a playground with the tube only? Maybe we can debug it together? The MeshBuilder was introduced, but the new version is backwards compatible. was works in 2.2 should work in 2.3 as well. @iiceman - just show us, we are not that bad! :-) Quote Link to comment Share on other sites More sharing options...
JohnK Posted October 19, 2015 Share Posted October 19, 2015 Tried to recreate the camera, lights etc as set in the maze. Tube not appearing in this playground. http://www.babylonjs-playground.com/#Q6CI As I said it worked fine last night????? Quote Link to comment Share on other sites More sharing options...
jerome Posted October 19, 2015 Share Posted October 19, 2015 Indeed... even the MeshBuilder version doesn't work : http://www.babylonjs-playground.com/#Q6CI#1 Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 19, 2015 Author Share Posted October 19, 2015 Ok, problem found. The MeshBuilder is missing the arc default value. I'll commit a fix, no idea when the playground will work again. You can always start using the new way of creating the meshes using the mesh builder, this will solve the problem in the playground... like this - http://www.babylonjs-playground.com/#Q6CI#2 Quote Link to comment Share on other sites More sharing options...
iiceman Posted October 19, 2015 Share Posted October 19, 2015 Well, I am not afraid that you "steal" my idea or something...you guys have always such great ideas and do way cooler stuff anyways. I was just afraid I ruin the surprise or something This is the current version of my maze: http://p215008.mittwaldserver.info/Maze/ It is inspired by the classic game "decent": https://en.wikipedia.org/wiki/Descent_(video_game) "M" toggles the map. Later the map will only be available at certain points in the maze. The violet gate is the exit, the green bouncy ball could be an enemy Bugging me 1: the flash light is flickering sometimes when moving around corners..it's just not as smooth as I imagined... but maybe that's just how it is. Bugging me 2: When you fly to the ground it's all cool. But if you fly to the ceiling somehow the camera goes trough. I tried adjusting the ellipsoid but I only get more distance to the ground but not the to the ceiling. There doesn't seem to be an ellipsoid offset for the camera, right? So not sure why that is happening, if anybody has an idea I would appreciate any hint. I can try to recreate it in the playground if that helps. adam and jerome 2 Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 19, 2015 Author Share Posted October 19, 2015 // ADD ENEMIES// TODO enemy movement - chase player? dodge? iiceman, should we be afraid? The map, the maze, so cool! About the flashlight - I actually thought it was a part of your design, I would simply leave it this way :-) But no idea why it is flickering from time to time. About the camera - I remember having the same problem. I think it is due to the ellipsoid not being the center of the camera, but its center of mass (This - the camera is your eyes, but the ellipsoid is actually the middle of your torso). I guess a larger ellipsoid didn't work. I sovled it somehow back then, but i forgot how. Perfect... I will try finding the code and let you know. Quote Link to comment Share on other sites More sharing options...
iiceman Posted October 19, 2015 Share Posted October 19, 2015 Yes you should be afraid but not sure if I can finish it in time, but I'll try! Yeah, I guess that flickering ain't that bad, maybe I really leave it. About the camera: larger ellipsoid only helps with the bottom, didn't help with the top. Would be awesome if you find that code. Maybe some offset value just like it's for the abstract mesh ellipsoid would be useful for the camera, too? Quote Link to comment Share on other sites More sharing options...
JohnK Posted October 19, 2015 Share Posted October 19, 2015 @RaananW thanks for fix for tube - entry now submitted RaananW 1 Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted October 19, 2015 Share Posted October 19, 2015 Woowwww iiceman!! Can't wait to see the final one!!! Quote Link to comment Share on other sites More sharing options...
iiceman Posted October 20, 2015 Share Posted October 20, 2015 @RaananW: did you have time to look for your code for fixing the ellipsoid yet? I think I found a way to get what I want for the camera by overwriting the _collideWithWorld method: var cameraOffsetY = 0.5; camera._collideWithWorld = function (velocity) { var globalPosition; if (this.parent) { globalPosition = BABYLON.Vector3.TransformCoordinates(this.position, this.parent.getWorldMatrix()); } else { globalPosition = this.position; } globalPosition.subtractFromFloatsToRef(0, this.ellipsoid.y - cameraOffsetY, 0, this._oldPosition); this._collider.radius = this.ellipsoid; //no need for clone, as long as gravity is not on. var actualVelocity = velocity; //add gravity to the velocity to prevent the dual-collision checking if (this.applyGravity) { //this prevents mending with cameraDirection, a global variable of the free camera class. actualVelocity = velocity.add(this.getScene().gravity); } this.getScene().collisionCoordinator.getNewPosition(this._oldPosition, actualVelocity, this._collider, 3, null, this._onCollisionPositionChange, this.uniqueId); };Not sure if that's good practice, though. Maybe this is my chance to do the tiniest contribution ever if I create a pull request for such an offset value? Well, maybe after I figured out how to set up a TypeScript environment So if anybody else thinks this is a good idea: don't wait for me, take all the glory for yourself and create a PR Quote Link to comment Share on other sites More sharing options...
MasterSplinter Posted October 22, 2015 Share Posted October 22, 2015 Well I totally spent most of my time trying to write my first algorithm to generate a maze randomly. But, I got it working! Now all I gotta do is plug it into babylon. And the rest is make it seksy. Here's my algorithm : https://github.com/wpdildine/babylon_maze_project/blob/master/js/maze.js Quote Link to comment Share on other sites More sharing options...
EJanuszewski Posted October 22, 2015 Share Posted October 22, 2015 I'm trying to use the new CreateTube Mesh but it doesn't quite look right http://puu.sh/kTrOH/0a47b2c439.jpg I can't do a playground test right now but here's my rough idea(yes I borrowed the texture example from a similar thing that John was doing) I'm not sure the tube is going to work the way I want it to, does anyone have suggestions on what might be a better thing to use? I was hoping to use like a cube and just remove the sides but I imagine it's not that simple. if (type == Box.TYPES.FORWARD) { level.paths.push(new BABYLON.Vector3(level.paths[level.paths.length - 1].x, 0, level.paths[level.paths.length - 1].z + 1)); } else if (type == Box.TYPES.RIGHT) { level.paths.push(new BABYLON.Vector3(level.paths[level.paths.length - 1].x + 1, 0, level.paths[level.paths.length - 1].z)); } else if (type == Box.TYPES.BACKWARD) { level.paths.push(new BABYLON.Vector3(level.paths[level.paths.length - 1].x, 0, level.paths[level.paths.length - 1].z - 1)); } else if (type == Box.TYPES.LEFT) { level.paths.push(new BABYLON.Vector3(level.paths[level.paths.length - 1].x - 1, 0, level.paths[level.paths.length - 1].z)); } var tube = BABYLON.MeshBuilder.CreateTube("tube", { path: level.paths, radius: 1.5, tessellation: 4, arc: 1 }, level.game.scene); material = new BABYLON.StandardMaterial("cmat", level.game.scene); material.diffuseTexture = new BABYLON.Texture("http://cubees.github.io/images/wire.jpg", level.game.scene); material.backFaceCulling = false; tube.material = material; tube.rotation.x = Math.PI / 4; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.