MV3D - 3D rendering for RMMV with Babylon.js

● ARCHIVED · READ-ONLY
Started by Cutievirus 1560 posts Page 46 of 78 View original ↗
  1. It's possible to create a firefly effect? Like those from magical forests, present in games like Zelda.

    I know there are particle effects plugins, but they are made to work in 2D, so the effects always follow the character where he goes, and in a 3D environment, it is not realistic. Including the RPG Maker's own rain and snow effects.

    Is there a way to make these effects look like in 3D games?
  2. SefirosuKuraodo said:
    So I updated to the latest version from the 0.4.8 version I was using to see if the recent fixes to sprites and such would allow Irina's DragonBones Sprites plugin to work with MV3D (it doesn't, in case anyone was curious... because I was curious :p) and I came across a change that I'm not sure is a bug, but is definitely a noticeable difference.
    Where the light limitation was concerned before, I found that by using the Glow function I could still achieve the illusion of brightly lit objects. Whatever sprite I applied the glow setting to would appear to be lit, and I was using FallenAngelOlivia's Bright Effects plugins to get a glowing hue around the object with Bloom settings. I designed a whole cave system with bioluminescent flowers and algae, and it worked quite well. However, with 0.5.1.5, the glow doesn't seem to have quite the same effect (in fact, while it certainly has a visible effect, it's not very visible and the difference between a glowing sprite and one that isn't glowing is minute.) Below are example of the flowers and algae set to glow(0.75) in 0.4.8, and the same flora with the same glow setting in 0.5.1.5.

    View attachment 136506
    View attachment 136510
    View attachment 136508
    View attachment 136509




    As you can see, the glow doesn't really 'pop' anymore. I'm not sure if the old version was in fact the bug and I just took advantage of it, but if anyone can help me work around the new darker glow I'd appreciate the help. I can just make the flowers mini lamps to get the same glow effect as the before pictures, but I'm not quite sure how to make the algae and waterfalls pop like before without having too many light sources, and taking away the gloomy darkness of the cave. Any help is appreciated ^^;
    this problem is happening to me too, in fact, it seems like the glow "glow(N)" doesn't even affect the event? it worked fine before the update, and i hope this is fixed soon as well......

    edit: i don't use any plugins that should affect the glow, nor ones mentioned in this, if it helps!
  3. I hate to keep piling onto the thread, but I just wanted to see if anyone else using Yanfly's Movement Core plugin is having issues with the current build? In 0.4.8, the "Move to: x, y" Script Call function for movement routes worked fine, but after I updated to 0.5.1.5, the function crashes my game if used on the player. It still works on event npc's, they'll go where directed, but using the function on the player will make the game crash. I tried turning off all of the new diagonal movement settings as well to see if that helped, but alas no mater what I try the game crashes.

    MoveCoreErr1.png
    MoveCoreErr2.png
  4. So I'm back after a looong time. I don't remember if this has been solved or not. But here's a problem: Ceiling disappears if I set wall height larger than 2.

    EDIT: Nvm. It was doing this: ceiling(A5,3,2,4) Instead of this: ceiling(A5,3,2|4)

    Btw, is there a way I can set pitch to be within a range? (Not allowing player to go to certain angles)
  5. @SefirosuKuraodo
    Those glowing objects are tiles right? This isn't a bug specific to 0.5, but there was a problem with how I was caching materials with a glow effect. When generating keys for materials with glow and materials with alpha, there was overlap in the bits used. I think that's probably what's happening.
    I have the bug fixed in 0.5.2, which is coming out soon.

    For the crash, I just tried it out. Seems like a classic load order problem. I change the processMoveCommand of Game_Player, then Yanfly changes processMoveCommand of Game_Character. So yanfly's code never gets run for the player.
    Move it above MV3D and it works fine.

    Your game looks stunning by the way.

    @Gabezin
    Babylon does support particle systems, though currently they aren't implemented in MV3D.
    If you're ambitious, you can try to implement it yourself.
    Particle System Intro | Babylon.js Documentation
    @Hyouryuu-Na
    Changing the wall height doesn't affect the ceiling.
    Currently the only way to change pitch range is to use script, though it might be a good idea if I made this configurable.
    For now, you can change this values. min is 0 and max is 180 by default.
    Note that changes in these values are not saved.
    mv3d.blendCameraPitch.min
    mv3d.blendCameraPitch.max
  6. @Dread_Nyanak Thanks! That works like a charm ^^
    Btw I realize the player can move at any angle now!? That's awesome!

    Edit: Any way to prevent this?:
    1584027162463.png
  7. Dread_Nyanak said:
    Those glowing objects are tiles right? This isn't a bug specific to 0.5, but there was a problem with how I was caching materials with a glow effect. When generating keys for materials with glow and materials with alpha, there was overlap in the bits used. I think that's probably what's happening.

    I should have specified, the waterfalls, the upright blue flowers, the smaller flat flowers, and the green flecks/colonies of algae are all events. Really, only the dirt ground and paths, the water itself, and the grass are tiles at the moment. I don't know if this makes a difference in relation to this bug or not.

    Dread_Nyanak said:
    Your game looks stunning by the way.

    Also, thank you! ^^
  8. Dread_Nyanak said:
    @Gabezin
    Babylon does support particle systems, though currently they aren't implemented in MV3D.
    If you're ambitious, you can try to implement it yourself.
    Particle System Intro | Babylon.js Documentation
    I would try, but I have no programming knowledge...

    Is there any chance of including these effects, even in the premium version?
  9. Gabezin said:
    I would try, but I have no programming knowledge...

    Is there any chance of including these effects, even in the premium version?
    There are many things I think about how to do rain. But it seems that the aforementioned explanation is explained as well as particles that are difficult to adapt to the situation as well. For example, rain, particles or increased smoke It's difficult to adjust With all the code itself. Hahaha. But it will be easier if he integrates it into a separate or main plugin.
    But yes, now I think that only raining is enough for me.
  10. Gabezin said:
    I would try, but I have no programming knowledge...

    Is there any chance of including these effects, even in the premium version?


    idk if it sounds...usefull, but you kinda can create big characters with the raindrops/leaves things falling/moving kinda animated, you could make multiple events animated at the same time, and to save memory, you could made a conditional branch checking at the player position to disable and enable the ones behind the character or the ones too far away to the character, so you could just animated kinda 5 - 8 events at the same time so fps dont go down too hard, that would made the rain kinda look 3d ish ... is kinda like the thing this guy does in this video to made fallen leaves



    but kinda bigger, if you know what i mean
  11. <mv3d>

    light(#366570)

    sun(black)

    </mv3d>

    If I don't enter the code above, the flashlight will not work or not. Is it possible to use the plug-in commands instead of adding notes to the map?
  12. Hyouryuu-Na

    You can change the parallax flooring so it doesn't turn black. Might use white instead, or adjust the camera angle to fit if it's too close to see through the wall

    Or set the floor to collapse instead and place situations like the door into the wall

    As the floor defaults do not have fillers inside, then look through

    (Change configuration from door to wall)

    And the way I make the flap, yes, it can be
    a little tricky but if you get used to it
    It's just copy paste
    This is the code event.
    <mv3d:shape(fence),scale(1,1),y(-0.49),z(0)>
  13. Dread_Nyanak said:
    @SefirosuKuraodo
    Those glowing objects are tiles right? This isn't a bug specific to 0.5, but there was a problem with how I was caching materials with a glow effect. When generating keys for materials with glow and materials with alpha, there was overlap in the bits used. I think that's probably what's happening.
    I have the bug fixed in 0.5.2, which is coming out soon.

    For the crash, I just tried it out. Seems like a classic load order problem. I change the processMoveCommand of Game_Player, then Yanfly changes processMoveCommand of Game_Character. So yanfly's code never gets run for the player.
    Move it above MV3D and it works fine.

    Your game looks stunning by the way.

    @Gabezin
    Babylon does support particle systems, though currently they aren't implemented in MV3D.
    If you're ambitious, you can try to implement it yourself.
    Particle System Intro | Babylon.js Documentation
    @Hyouryuu-Na
    Changing the wall height doesn't affect the ceiling.
    Currently the only way to change pitch range is to use script, though it might be a good idea if I made this configurable.
    For now, you can change this values. min is 0 and max is 180 by default.
    Note that changes in these values are not saved.
    mv3d.blendCameraPitch.min
    mv3d.blendCameraPitch.max

    I tried following that link and managed to get the sun example working. No idea how to move it but it worked.

    Code:
    var createScene = function () {
    
    
        // Setup environment
        var camera = new BABYLON.ArcRotateCamera("ArcRotateCamera", 1, 0.8, 5, new BABYLON.Vector3(0, 0, 0), mv3d.scene);
        camera.attachControl(mv3d.canvas, true);
    
        // Create a particle system
        var surfaceParticles = new BABYLON.ParticleSystem("surfaceParticles", 1600, mv3d.scene);
    
        // Texture of each particle
        surfaceParticles.particleTexture = new BABYLON.Texture("T_SunSurface.png", mv3d.scene);
    
        // Create core sphere
        var coreSphere = BABYLON.MeshBuilder.CreateSphere("coreSphere", {diameter: 2.01, segments: 64}, mv3d.scene);
    
        // Create core material
        var coreMat = new BABYLON.StandardMaterial("coreMat", mv3d.scene)
        coreMat.emissiveColor = new BABYLON.Color3(0.3773, 0.0930, 0.0266);
    
        // Assign core material to sphere
        coreSphere.material = coreMat;
    
        // Pre-warm
        surfaceParticles.preWarmStepOffset = 10;
        surfaceParticles.preWarmCycles = 100;
    
        // Initial rotation
        surfaceParticles.minInitialRotation = -2 * Math.PI;
        surfaceParticles.maxInitialRotation = 2 * Math.PI;
    
        // Where the sun particles come from
        var sunEmitter = new BABYLON.SphereParticleEmitter();
        sunEmitter.radius = 1;
        sunEmitter.radiusRange = 0; // emit only from shape surface
    
        // Assign particles to emitters
        surfaceParticles.emitter = coreSphere; // the starting object, the emitter
        surfaceParticles.particleEmitterType = sunEmitter;
    
        // Color gradient over time
        surfaceParticles.addColorGradient(0, new BABYLON.Color4(0.8509, 0.4784, 0.1019, 0.0));
        surfaceParticles.addColorGradient(0.4, new BABYLON.Color4(0.6259, 0.3056, 0.0619, 0.5));
        surfaceParticles.addColorGradient(0.5, new BABYLON.Color4(0.6039, 0.2887, 0.0579, 0.5));
        surfaceParticles.addColorGradient(1.0, new BABYLON.Color4(0.3207, 0.0713, 0.0075, 0.0));
    
        // Size of each particle (random between...
        surfaceParticles.minSize = 0.4;
        surfaceParticles.maxSize = 0.7;
    
        // Life time of each particle (random between...
        surfaceParticles.minLifeTime = 8.0;
        surfaceParticles.maxLifeTime = 8.0;
    
        // Emission rate
        surfaceParticles.emitRate = 200;
    
        // Blend mode : BLENDMODE_ONEONE, BLENDMODE_STANDARD, or BLENDMODE_ADD
        surfaceParticles.blendMode = BABYLON.ParticleSystem.BLENDMODE_ADD;
    
        // Set the gravity of all particles
        surfaceParticles.gravity = new BABYLON.Vector3(0, 0, 0);
    
        // Angular speed, in radians
        surfaceParticles.minAngularSpeed = -0.4;
        surfaceParticles.maxAngularSpeed = 0.4;
    
        // Speed
        surfaceParticles.minEmitPower = 0;
        surfaceParticles.maxEmitPower = 0;
        surfaceParticles.updateSpeed = 0.5;
    
        // No billboard
        surfaceParticles.isBillboardBased = false;
    
        // Start the particle system
        surfaceParticles.start();
    
        return mv3d.scene;
    }

    Managed to get the starting position of the sphere to change with.
    Code:
        coreSphere.x = 5;
        coreSphere.y = 5;
        coreSphere.z = 10;
    Sun.png
    Not sure how to move it mid game though. Camera stuff at top doesn't seem to be needed.

    Got it to move with
    Code:
    mv3d.scene.rootNodes[11].z = 1
    Just no idea how to get the array index of it.

    Sorta got it to a static place with
    Code:
    mv3d.thing = coreSphere;
    at the end, then mv3d.thing.z = 1; sets it to 1 z.

    Been trying to adjust scale but the particles don't seem to scale with it with coreSphere.scaling.x = but did get an interesting effect from playing with random numbers.
    Sun


    Code:
        surfaceParticles.minSize = 0.8;
        surfaceParticles.maxSize = 1.4;
    Those seem to need to change with the size for it to work.

    Not exactly smooth particle movement but it works.

    Sun2
  14. @Hyouryuu-Na
    The camera clipping through walls? Currently, no, unfortunately. I plan on adding some sort of camera collision soon though. Maybe in 0.5.3.

    @SefirosuKuraodo
    I just tried out the old version. You're right, glow wasn't working for events. While working on 0.5.2 I must have fixed it without noticing.
    Anyway, try the new version.

    @Gabezin
    Particles would be a great feature for the premium plugin. I might add them eventually, but probably not soon.

    Update 0.5.2:
    new plugin command mv3d animation, plays animations that can be occluded in 3d and have custom scales.
    glow can now take a color instead of a number (but can still take numbers if you want)
    glow actually works
    blend modes now supported
    render distance dynamically reduced on maps with really thick fog

    Premium:
    Transparent objects (such as with bush transparency) can now cast shadows, and are rendered properly with alpha fog.
    New glow effect
    Skyboxes!


    mv3d_skybox.png
  15. Dread_Nyanak said:
    @Hyouryuu-Na
    The camera clipping through walls? Currently, no, unfortunately. I plan on adding some sort of camera collision soon though. Maybe in 0.5.3.

    @SefirosuKuraodo
    I just tried out the old version. You're right, glow wasn't working for events. While working on 0.5.2 I must have fixed it without noticing.
    Anyway, try the new version.

    @Gabezin
    Particles would be a great feature for the premium plugin. I might add them eventually, but probably not soon.

    Update 0.5.2:
    new plugin command mv3d animation, plays animations that can be occluded in 3d and have custom scales.
    glow can now take a color instead of a number (but can still take numbers if you want)
    glow actually works
    blend modes now supported
    render distance dynamically reduced on maps with really thick fog

    Premium:
    Transparent objects (such as with bush transparency) can now cast shadows, and are rendered properly with alpha fog.
    New glow effect
    Skyboxes!

    One problem I see with plugin animation is it seems to use alpha cutoff parameter, which cuts off a lot of animations stuff. Also skybox seems to cause lag with alpha fog on, not gonna use the skybox personally anyway though since I don't plan on yaw changes.

    Yeah I tried animation 12 and 13 but they don't even play even at 0.01, 13 plays a flash only.

    Actually they do play, it seems they don't work on blank tiles though and the parts off the tile get cut off, though my other 1 works off tile.

    Testing more it's mainly different blends that are weird, normal works fine, additive doesn't play on empty tiles but works elsewhere, screen and multiply seems to have same cutoff problem on empty tiles and extra white/black square stuff shown elsewhere.
  16. @Dread_Nyanak if you are thinking about using particles in the future, may I suggest taking a look, and talking to, Pivoo?
    He made this one, that seems a bit unfinished but it is mostly user-oriented, particle effects focused on an event or battle instead of the whole screen, it is perfectly useable for anything if you actually program in it.
    Of course, the plugin itself has an "error message" for using paths, but after I talked with him and tried fixing this we found out that we just had to use the more recent version of pixi particle and remove the message, they were already useable.

    I'm finally with some free time, spent the last weeks dealing with moving out of town (and state) for university, so I wasn't able to see the new things, or even adapt my patches for the new versions, glad someone already did it for some things :D
  17. LAST VERSION : 0.5.2
    BIG ERROR
    ClipBoard-2.png
    I find new version with MOG_ChronoEngine.js conflict .

    222.png
    I find new version with MOG_ChronoToolHud.js conflict .

    Please help it.
  18. CoopNinjask said:



    @Dread_Nyanak
    It's almost perfect. You fixed most bugs, but there are still a few left.
    Here goes:

    1) Character Sprites bugs have not been fixed completely:
    While it was fixed almost completely, there is a specific situation in which it keeps happening.
    There must be some specific exception in the code where the fixes you made did not apply.
    a) Entire sprite sheet for 1 frame problem is still happening (00:03, 00:14 and 00:17 in the video): I rarely manage to do this bug happens, but sometimes i did. This is more likely to happen as soon as the game loads.
    b) Wrong sprite index for 1 frame (00:08 in the video): I managed to do this happens in the same conditions that the bug above, rarely.

    2) Strange behavior in parallaxes using DhoomParallaxUtils (00:30 in the video):
    At certain coordinates on the map, the parallaxes seems to reset their position or reload the file, causing a weird parallax effect.
    I tested it in previous versions and it doesn't happen in version 0.4.8 and earlier.
    This bug started to happen from version 0.5 onwards, but I only discovered this bug now.
    This doesn't happen with normal parallaxes, but I need to use DhoomParallaxUtils to make smooth transitions between the day phases in the Environment System.
    I included the tests with versions 0.4.8 and 0.5.1 in the video for comparison, besides of 0.5.1.5.

    I think this time, you will manage to make it totally bug free.


    I have tested the new 0.5.2 version.
    You did awesome updates, great job!

    The bugs that i mention in this quote still happening, though.

    Besides that, can you add a option to choose the normal bias from shadow generator?
    This would help us to better set the shadows behavior and get rid of self-shadowing issues.

    It would be possible you add a option to emulate 0.4.8 behavior related to parallaxes?
    This bug don't occurs in the mentioned version, but your improved and new features are too interesting to give up.
    (Or maybe, add a option to fade default parallaxes, if this is easier to do)
  19. seaotter said:
    LAST VERSION : 0.5.2
    BIG ERROR
    View attachment 136991
    I find new version with MOG_ChronoEngine.js conflict .

    View attachment 137052
    I find new version with MOG_ChronoToolHud.js conflict .

    Please help it.
    is mv3d above or bellow the chrono engine files? did you try changing their position?
    because position matters in plugins. A lot.
  20. Waterguy said:
    is mv3d above or bellow the chrono engine files? did you try changing their position?
    because position matters in plugins. A lot.
    sure, I try above or bellow. ( I know javescript have this problem )

    Commits · Electravirus/MV3D
    ( I try much version )

    Version Commits on Mar 8, 2020 can be ok

    Version Commits on Mar 9, all versions after 2020 have this problem

    So I guess
    animation flash sprite
    Dread-chan committed 7 days ago


    What changed to cause this result