Compatibility between Galvs Message Busts and MBS Map Zoom

Discussion in 'JS Plugin Requests' started by styx92, Dec 13, 2016.

  1. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
    Hey there.


    I make it short. I use Galv message busts and the MBS Map Zoom plugin. It works pretty together without crashs or else, but if i have a message bust and at the same time i have zoomed in or out, the message bust dont geht zoomed. Than it looks so:
     

    Unbenannt.PNG


    Ignore the black lines, this is a permant problem of zoom scripts xD
    But you see my problem :D
    In the MBS Zoom Script is a function to get pictures zoomed if you write [zoom] behind the picture name "lol [zoom].png" for example. This only works with the normal "show picture" - command.

    I thought there must be a way to get this message bust zoomed in the same way as the normal pictures.


    Thanks for reading, i hope someone can help =)

    PS: if someone knows how to delete this black lines by zooming, this would be nice to know, too :D


    greez BD
     
    #1
  2. Jonforum

    Jonforum Veteran Veteran

    Messages:
    1,580
    Likes Received:
    1,360
    Location:
    Canada / Québec
    First Language:
    French
    Primarily Uses:
    RMMV


    Using the same plugin as you, for my project.
    I was faced with the same problem.
    My fight is done with images and a zoom on the heroes before.
    You must unfortunately use the script to display and move at the same time zoom your images.
    The formula must be made in relation to your resolution, you should also made some a lot test.
    Try Store your zoom Var X, Y and make a picture move with your Own formule.


    Did you try


    // X, Y , You need store and make multi test with your formula 


    var x= ??;
    var y= ??;
    var duration = ??;
    // need set MapZoom center event id befor if need or MapZoom center x y
    $gameMap.setZoom(x, y, duration); // X, Y are the scale
    $gameScreen.movePicture(pictureId, origin, x, y, scaleX, scaleY, opacity, blendMode, duration)


    When all ok , you can make a little function


    function CallZoom1(x,y,duration) {
    //all you zoom code
    }

    // And call this to use you zoom forumula

    CallZoom1(?,?,?);


    ps: i no have black line 
     
    Last edited by a moderator: Dec 14, 2016
    #2
    styx92 likes this.
  3. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
    #3
  4. Krimer

    Krimer Veteran Veteran

    Messages:
    135
    Likes Received:
    101
    Location:
    Kiev, Ukraine
    First Language:
    Ukrainian
    I can't understand your problem. Busts zoom in when you call MapZoom, yes, they moved lower but they are zoomed. 


    You want something like this?

    [​IMG]

    Pictures zoom works in the same way as showed in gif.
     
    #4
    styx92 likes this.
  5. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
     Yes thats right.


    Sorry thats my bad, i told you wrong :o
    Of course i mean that the picture is not at the same place like before. I should be at the same place. And it sould NOT zoom.
     
    #5
  6. Krimer

    Krimer Veteran Veteran

    Messages:
    135
    Likes Received:
    101
    Location:
    Kiev, Ukraine
    First Language:
    Ukrainian
    So you need this?

    [​IMG]
     
    #6
    Jonforum likes this.
  7. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
    :o
    Yes... so i need it. How you fixed it?
     
    #7
  8. Krimer

    Krimer Veteran Veteran

    Messages:
    135
    Likes Received:
    101
    Location:
    Kiev, Ukraine
    First Language:
    Ukrainian
    find in mapzoom plugin function called 


    Spriteset_Map.prototype.updatePosition


    and add to the end of function this 


    if (!this._msgBustSprite) return;
    this._msgBustSprite.scale = new PIXI.Point(1.0 / scale.x, 1.0 / scale.y);
    this._msgBustSprite.y = this._msgBustSprite.y / scale.y


    i can create mini addon for this but it so small so do it by yourself :)
     
    #8
    Jonforum likes this.
  9. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
    A mini add on, or the updated map zoom plugin, would be nice. I dont have knowlegde for scripts :D

    This function works only if galvs message bust plugin calls the busts right?
     
    #9
  10. Krimer

    Krimer Veteran Veteran

    Messages:
    135
    Likes Received:
    101
    Location:
    Kiev, Ukraine
    First Language:
    Ukrainian
    oh, ok, then add this to the end of plugin

    Code:
    Map_Zoom_Alias_Spriteset_Map_updatePosition = Spriteset_Map.prototype.updatePosition;
    Spriteset_Map.prototype.updatePosition = function() {
    	Map_Zoom_Alias_Spriteset_Map_updatePosition.call(this)
    	var scale = $gameMap.zoom;
    	if (!this._msgBustSprite) return;
    	this._msgBustSprite.scale = new PIXI.Point(1.0 / scale.x,  1.0 / scale.y);
    	this._msgBustSprite.y = this._msgBustSprite.y / scale.y
    };
     
    Last edited by a moderator: Dec 14, 2016
    #10
    Jonforum, Galv and styx92 like this.
  11. styx92

    styx92 Veteran Veteran

    Messages:
    310
    Likes Received:
    38
    First Language:
    German
    Oh my god ! :D
    It works! It works! :D Thank you! This is really awesome.
     
    #11

Share This Page