Pokemon Red/Blue Chaos Edition


Pokemon Red/Blue Chaos Edition



I'm trying to make a Pokemon Red/Blue Chaos Edition, but like everyone else asking question on this site, I've encountered a bug that I cannot fix. I am using version 2.2.2 (x64) of BizHawk. The error is as follows:


NLua.Exceptions.LuaScriptException: [string "main"]:12: invalid arguments to method call



https://pastebin.com/pWmByXum



I did some research, and came to the conclusion that it's trying to run line 12 as a function even though I have none.




1 Answer
1



rng is being defined as a local variable inside the if block. It is therefore not available outside of that block when it is used as an argument to the call on line 12. At that point it would be nil. Move the declaration of rng to above the if block:


rng


if


nil


if


local rng = nil



Then in both places in fhe if block when you assign a value, just write:


if


rng = ...



instead of


local rng = ...






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

api-platform.com Unable to generate an IRI for the item of type

How to set up datasource with Spring for HikariCP?

Display dokan vendor name on Woocommerce single product pages