TomaszFurca

Members
  • Content count

    67
  • Joined

  • Last visited

About TomaszFurca

  • Rank
    Advanced Member

Recent Profile Visitors

359 profile views
  1. Slavs - slavian rpg game

    Check new version of preview: - character select - New lights - character select - new sounds Live: babylon.furcatomasz.pl
  2. Good tips. Already changed looping my colliders array in scene after render function to action manager, because action manager is fired only when object intersect, so i do need to check all colliders in camera frumstrum. Next good point to optimize my game. Also I fixed PG https://www.babylonjs-playground.com/#WWCK0#41. You need to set parameter in action manager. Parameter value is mesh with which you want register function.
  3. Hi, I think the best option would be use intersect with mesh -> https://doc.babylonjs.com/tutorials/intersect_collisions_-_mesh.
  4. Hi, after finish inventory GUI in my game - babylon.furcatomasz.pl I have small problem with mesh rotation after mount item to bone. For reproduce problem open my game, open inventory and click to any sword to change, then mounted item has wrong rotation. its my code to mount item: mesh.attachToBone(bone, meshCharacter); mesh.position = new BABYLON.Vector3(0, 0, 0); bone.getRotationToRef(BABYLON.Space.WORLD, meshCharacter, mesh.rotation); mesh.rotation = mesh.rotation.negate(); mesh.rotation.z = -mesh.rotation.z; Variable mesh is item to equip. Thanks for help, Tom.
  5. Intersect and Frumstrum

    Thanks for replay, but what you think about this scenario. Player - have register function in render loop too check collisions with colliders (this is array of all meshes in scene, which are colliders for player). In loop are meshes, which we don't see on camera.
  6. Intersect and Frumstrum

    Hi, in my project i have a lot modules which must register anonymous function in sceneAfterRender. Some of them uses intersectsMesh. What you think about check mesh is active, before check intersects? For example checking player collisions, with only colliders, which are visible in camera: for (var i = 0; i < colliders.length; i++) { var mesh = game.sceneManager.environment.colliders[i]; if(scene.isActiveMesh(mesh)) { if (this.mesh.intersectsMesh(sceneMesh, false)) { ... } } } Tomasz Furca
  7. GUI panel positions problem

    It works! Thanks a lot for help. https://www.babylonjs-playground.com/#59N785#9 Additionaly with window resize event i change positions to correct
  8. GUI panel positions problem

    Rectangle is not expanded so ok - https://www.babylonjs-playground.com/#59N785#4. Is possible to auto set positions of childrens of rectangle panel (for example set x% from left and x% from top)? I can set it mannualy, but after resize windows always i must change position values (left, top). How about set correct position of rectangle panel on inventory background? Do you have any tip, how do that correct?
  9. GUI panel positions problem

    Okey :). First point line 63 has been changed, because i want manage all childrens of main container calling for example texture.removeFromControl(cotainer). https://www.babylonjs-playground.com/#59N785#2 Second point, panelItems (stackPanel) have width 0.33 on fullscreen texture with non vertical positions. I added three images with 0.2 width to this panel. Then this panel has been expanded, but i want keep width of panel and add image wrapping to panelItems. https://www.babylonjs-playground.com/#59N785#1. Remove one item from panel and check what happen: https://www.babylonjs-playground.com/#59N785#3. Third point maybe resolved when we fix realize first. Fourth point is theory question :).
  10. GUI panel positions problem

    Hi, I working on GUI in game and i have problem with many panels. What i want to do? 1. set panelItems container in main panel named in my PG as container. Now i must add it on guiTexture to correct display. 2. set iconsImages in my panelItems with wrapping images in panel, now items increase height of panelItems. 3. Is it possible to correct resize panel items to imageContainer (when first point has been resolved). At this moment, when i resize window i lost correct position and size of panelItems, because image in imageContainer is stretched. 4. Should I make fixed resolution in my game, and then for every available resolution set correct values of position? https://www.babylonjs-playground.com/#59N785#1 Thanks for help Tomasz Furca
  11. [solved] PointUp event and BABYLON.GUI

    After many tests i do not know why isPointerBlocker not work. So your tip about register function onEnter and onOut is perfect. Now my code, makes my game GUI more user friendly let self = this; control.onPointerEnterObservable.add(function() { self.game.sceneManager.environment.ground.isPickable = false; }); control.onPointerOutObservable.add(function() { self.game.sceneManager.environment.ground.isPickable = true; }); Additionally I used your code from PG and it don't work too. Thanks @Wingnut
  12. [solved] PointUp event and BABYLON.GUI

    I tested this flag in my project -> babylon.furcatomasz.pl, but without positive results. In PG it works fine... Later i will check setting my pointer events in other positions of my project, maybe this is problem, maybe imported scene - i don't know I must check it. Thanks for show good way to resolve this problem.
  13. Slavs - slavian rpg game

    Check new preview of our game!
  14. Yesterday i add simple GUI buttons to my game. I have problem with pointer event, when i click to button pointer event send data with selected mesh (I think about ground instead button) and now i logic of my game, if i select ground player move to this point. Is possible to block pointer event when i click to my button? Tom
  15. Exporter (Model and Colliders)

    Maybe add box colliders (named for example collider_xxx) as childs of main mesh, then you can create manager in JS, which check all meshes in scene. If your manager found in children name colider_xxx implement on it collision functionality. In my project after load scene I push all meshes to array (simple cache) on which i want check collisions, for that i use intersectMesh with my Player mesh. After tests with physics, intersects have better performance.