andy5995 Posted March 6 Share Posted March 6 (edited) I thought I made the necessary change to a couple maps from the community-maps-2 mod But when I try starting a game with one of the maps I've changed, I get this: Edited March 6 by andy5995 fix typographical error Link to comment Share on other sites More sharing options...
Stan` Posted March 7 Share Posted March 7 I imagine there is nothing in the porting guide ? Cc @phosit Link to comment Share on other sites More sharing options...
hyperion Posted March 7 Share Posted March 7 Would be nice if you actually copied the error message as text (the image doesn't load for me) so a blind guess is you use SetProgress instead of yield. 1 Link to comment Share on other sites More sharing options...
Arup Posted March 7 Share Posted March 7 53 minutes ago, hyperion said: Would be nice if you actually copied the error message as text (the image doesn't load for me) so a blind guess is you use SetProgress instead of yield. the image is this: Link to comment Share on other sites More sharing options...
phosit Posted March 7 Share Posted March 7 You need to import the functions you are using something like import { addAnimals, addBerries, addBluffs, addDecoration, addForests, addHills, addLayeredPatches, addMetal, addStone, addStragglerTrees, createBluffsPassages, markPlayerAvoidanceArea } from "maps/random/rmgen2/gaia.js"; 1 Link to comment Share on other sites More sharing options...
andy5995 Posted March 7 Author Share Posted March 7 11 hours ago, phosit said: You need to import the functions you are using something like import { addAnimals, addBerries, addBluffs, addDecoration, addForests, addHills, addLayeredPatches, addMetal, addStone, addStragglerTrees, createBluffsPassages, markPlayerAvoidanceArea } from "maps/random/rmgen2/gaia.js"; @phositWhen I uncomment the line `Engine.LoadLibrary("rmgen2");` I get the error: ERROR: JavaScript error: maps/random/rmgen2/gaia.js line 1 import declarations may only appear at top level of a module @maps/random/cliffs_of_carnage.js:7:8 ERROR: CMapGenerationCallbacks::LoadScripts: Failed to load script 'maps/random/rmgen2/gaia.js' ERROR: An unhandled promise got rejected: ReferenceError: e_p is not defined @maps/random/cliffs_of_carnage.js:386:1 @Stan`What's the link to the porting guide? Link to comment Share on other sites More sharing options...
andy5995 Posted March 7 Author Share Posted March 7 5 minutes ago, andy5995 said: @phositWhen I uncomment the line `Engine.LoadLibrary("rmgen2");` I get the error: ERROR: JavaScript error: maps/random/rmgen2/gaia.js line 1 import declarations may only appear at top level of a module @maps/random/cliffs_of_carnage.js:7:8 ERROR: CMapGenerationCallbacks::LoadScripts: Failed to load script 'maps/random/rmgen2/gaia.js' ERROR: An unhandled promise got rejected: ReferenceError: e_p is not defined @maps/random/cliffs_of_carnage.js:386:1 @Stan`What's the link to the porting guide? Oh, I think I see. I'll start with a change like this: https://gitea.wildfiregames.com/0ad/0ad/commit/2d43ca6462940e9c3aad82309e41febb53892654?files=binaries%2fdata%2fmods%2fpublic%2fmaps%2frandom%2ffrontier.js Link to comment Share on other sites More sharing options...
andy5995 Posted March 7 Author Share Posted March 7 I made some progress, I'll check back when I have more questions. @Stan` I could still use a link to the porting guide though. Link to comment Share on other sites More sharing options...
Stan` Posted March 8 Share Posted March 8 https://gitea.wildfiregames.com/0ad/0ad/wiki/PortA27ToR28 1 Link to comment Share on other sites More sharing options...
Grapjas Posted March 8 Share Posted March 8 @andy5995https://gitea.wildfiregames.com/0ad/0ad/wiki/Release28 might also be of interest to you. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now