1. Dismiss Notice
  2. Within our Resources section we have over 150 Audio files, with room to grow. You may find exactly what you have been looking for. Just CLICK HERE to start your listening adventure.
    Dismiss Notice
  3. Why would you want to upload your resources directly to RMMV.co? It makes it easier for other members to download them. Click HERE for more information.
    Dismiss Notice
  4. Click HERE to see our four new featured resources by TheUnproPro, Starbird, iblamevictoria, and VGM MarkH.
    Dismiss Notice
  5. Here are the The Resource Rules.
    Dismiss Notice
  6. Please read these RULES before posting.
    Dismiss Notice

TypeError

Discussion in 'Javascript Support' started by Fablerede, Feb 4, 2018.

Thread Status:
Not open for further replies.
  1. Why am i getting this error in these yanfly scripts?

    TypeError: Failed to execute 'getImageData' on 'CanvasRenderingContext2D': float parameter 1 is non-finite.
    at TypeError (native)
    at Bitmap.getPixel (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_core.js:1195:30)
    at Window_TitleCommand.Window_Base.textColor (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_windows.js:176:28)
    at Window_TitleCommand.Window_Base.normalColor (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/plugins/YFCore.js:4518:15)
    at Window_TitleCommand.Window_Base.normalColor (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/plugins/YEP_ItemCore.js:1358:48)
    at Window_TitleCommand.Window_Base.resetTextColor (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_windows.js:106:31)
    at Window_TitleCommand.Window_Base.resetFontSettings (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_windows.js:102:10)
    at Window_TitleCommand.Window_Base.resetFontSettings (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/plugins/YEP_MessageCore.js:687:50)
    at Window_TitleCommand.Window_Base.createContents (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_windows.js:96:10)
    at Window_TitleCommand.Window_Base.initialize (file:///C:/Users/maxam/Documents/Games/Harem%20Quest/js/rpg_windows.js:24:10)
     
  2. You should provide more information such as how the error is being triggered. Is it on script initialization? Is it only when using some sort of command?

    Parameter 1 is "The x coordinate of the upper left corner of the rectangle from which the ImageData will be extracted."

    What immediately comes to mind to me is that parameter (and likely the others) aren't being properly loaded. This may be because the image itself hasn't finished loaded by the time the instruction is called.

    Apparently this issue was common in a lot of YF's older scripts, so make sure you're using the most current versions.

    Also, this forum isn't for support questions. Instead of asking here I highly suggest seeking support from one of the script sources posted by YF themselves.
     
  3. It's when i push test play and after the YF splash screen, and afaik it is the most current versions
     
  4. Try disabling every non-related plugin. It looks like it needs YFCore, YEP_ItemCore, and YEP_MessageCore so disable everything except those.

    It might be a compatibility issue. If this fixes the issue try turning on one plugin at a time until the error resurfaces. Since I'm not actually too familiar with YF's scripts this is probably the most help I'll be able to give. If it is a compatibility issue you'll probably have to decide on what plugin to cut (or contact the plugin creator to see if they can make it compatible.)
     
  5. hmm it might just be a compatibility issue, i disabled all the plugins except those three and it still throws me back the error
    --- Double Post Merged, Feb 4, 2018, Original Post Date: Feb 4, 2018 ---
    so it turns out that it was throwing me the error because i had renamed the js file -.-
     
  6. Thread closed now due to the problem being solved. (cool)
     
Thread Status:
Not open for further replies.

Share This Page

Loading...