Jump to content

Recommended Posts

Hello

I create a language mod. I write a lua script who add a new font to game. When I activate mod in menu, game work and load a new fonts. When I play new game, Don't Starve crash after loading. Sometimes game show first scene but when the subtitles may shows, game crash.

In attachment include my lua script.

modmain.lua

In 90% I solved my problem.

 

What means this error:

Assert failure 'mRenderParams.m_font != INVALID_RESOURCE_HANDLE' at ..\source\game\render\textnode.cpp(386): Trace follows...

This error shows in log when I play with "Wigfrid" and my game crash when my character will talked.

I believe this means that the filepath is invalid. Maybe you could try to use "resolvefilepath" to fix it, but maybe it breaks the mod entirely.

GLOBAL.resolvefilepath("fonts/talkingfont__sw.zip")

You have all the font files mentioned in modmain, right?

Thanks you! You entered me to solve this problem. I forgot add a ".zip" to "talkingfont_wathgrithr__sw".

I change this:

GLOBAL.TheSim:LoadFont(MODROOT.."fonts/talkingfont_wathgrithr__sw", "talkingfont_wathgrithr")

to

GLOBAL.TheSim:LoadFont(MODROOT.."fonts/talkingfont_wathgrithr__sw.zip", "talkingfont_wathgrithr")

Now it's all works.

Thanks for your help.

I have a new problem :(

I added a new textures to game:

Assets={
	Asset("ATLAS",MODROOT.."modicon.xml"),
	Asset("ATLAS",MODROOT.."images/customisation.xml"),
	Asset("ATLAS",MODROOT.."images/customization_shipwrecked.xml"),
	Asset("ATLAS",MODROOT.."images/fepanels.xml"),
	Asset("ATLAS",MODROOT.."images/fepanels_DSTbeta.xml"),
	Asset("ATLAS",MODROOT.."images/fepanels_ps4.xml"),
	Asset("ATLAS",MODROOT.."images/motd.xml"),
	Asset("ATLAS",MODROOT.."images/upgradepanels.xml"),
	Asset("ATLAS",MODROOT.."bigportraits/locked.xml")
	}

When I activate mod, it's works all. I have in game my textures.

 

When I exit the game and I play again (mod automacily activate) it's work with my texture, but when I deactivate mod the default textures don't loaded, I have a empty places (in this 8 textures).

 

When I deactivate mod --> exit game --> run game --> activate mod --> deactivate mod, default textured loaded.

When I activate mod --> exit game --> run game --> deactivate mod, default textured don't loaded.

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...