Jump to content

Recommended Posts

Strange, my steam copy is, but not my stand-alone. Same crash on both though...

?It's not commented!@components/overseer.lua

 27 function FightStat_Equip(item,slot) 28     GetPlayer().components.overseer:Equip(item,slot) 29 end
But anyway, I'll see if I can track this down.

I've lost count how many times I've had to explain to folks the simplest thing (installing a mod) but many people still get things goofed up (usually taking the zip download and doing an 'unzip to' - this almost always results in the mod installing two directories down and not working). I think a simple mod installer of some sort would be a great addition to the game.On the Mod Screen > install mod > dialog box that let's them find the downloaded zip file and the zip is automatically installed correctly where it belongs and also removes the existing mod folder first.I could write this easy enough in visual basic, but it needs to be launched from the Mod Screen.Minecraft mod installers don't even unzip the zip file, but the mod is run from there.Anyway, just a thought.

Edited by tehMugwump
  • Developer

But I'm posting this here because, upon finally running the Test Tools for actual testing (huh), I realized something quite a bit more strange. Nothing appears for me, under Linux. I tried booting into Windows, and over there everything is fine (except for these minor issues, such as the invisible Slurper). But under Linux this is what I get:

Everything is functional: I can click on the spinners, I hear a sound and they actually do the spinning. Except that everything is invisible. :p

So perhaps Ipsquiggle here might have some clue on what could be OS sensitive about the mod's contents. I never had any graphical issues with Don't Starve, and log.txt doesn't give any errors or warnings. It's so weird.

This is just a shot in the dark, but: Filesystem case sensitivity? I'll have a further look into it soon though.
  • Developer

Definitely the error handling is due for a bit of an upgrade. As Simplex mentioned, the reason for the "Disable Everything" behavior is because at that point we don't know which mod caused the error and it's also not possible to get to the mods screen to manually disable mods. So the behaviour we chose (and this was in a rush to solve live crashes after last update) was to just disable all the mods, and then you can re-enable them manually.

There are a few problems with it; first, it happens during map gen and savegame loading, which don't block your access to the mods screen. So in those cases we could probably not disable everything (though I believe we still can't show an error or detect which mod it was).

The other problem is definitely re-enabling everything. I'm extremely hesitant to have any kind of "enable all" button because for most users it will just cause the game to crash again (by re-enabling the broken mod, and potentially other broken mods which were previously disabled).

At this point I'd prefer to have most users systems bail out of mods aggressively in order to preserve the game running. I do, however, have a plan to bring modsettings.lua back into the loop, to allow mod developers to force-enable mods, so that during development you don't have to work through the menus every time something breaks.

[MENTION=10028]tehMugwump[/MENTION] does this seem like it would solve the frustration you're having? If not we can come up with something better. :)

  • Developer

I've lost count how many times I've had to explain to folks the simplest thing (installing a mod) but many people still get things goofed up (usually taking the zip download and doing an 'unzip to' - this almost always results in the mod installing two directories down and not working). I think a simple mod installer of some sort would be a great addition to the game.On the Mod Screen > install mod > dialog box that let's them find the downloaded zip file and the zip is automatically installed correctly where it belongs and also removes the existing mod folder first.I could write this easy enough in visual basic, but it needs to be launched from the Mod Screen.Minecraft mod installers don't even unzip the zip file, but the mod is run from there.Anyway, just a thought.

Yeah, we definitely want to improve this further, it's a question of scheduling right now. At the least, there's Steam Workshop coming in this week! That will help a lot and really increase the reach of your mods. :)

Yes, I see your point with enabling all causing trouble. I agree. I was just in a *****y mood, so don't lose any sleep over mod enabling. :p

Definitely the error handling is due for a bit of an upgrade. As Simplex mentioned, the reason for the "Disable Everything" behavior is because at that point we don't know which mod caused the error and it's also not possible to get to the mods screen to manually disable mods. So the behaviour we chose (and this was in a rush to solve live crashes after last update) was to just disable all the mods, and then you can re-enable them manually.

There are a few problems with it; first, it happens during map gen and savegame loading, which don't block your access to the mods screen. So in those cases we could probably not disable everything (though I believe we still can't show an error or detect which mod it was).

The other problem is definitely re-enabling everything. I'm extremely hesitant to have any kind of "enable all" button because for most users it will just cause the game to crash again (by re-enabling the broken mod, and potentially other broken mods which were previously disabled).

At this point I'd prefer to have most users systems bail out of mods aggressively in order to preserve the game running. I do, however, have a plan to bring modsettings.lua back into the loop, to allow mod developers to force-enable mods, so that during development you don't have to work through the menus every time something breaks.

[MENTION=10028]tehMugwump[/MENTION] does this seem like it would solve the frustration you're having? If not we can come up with something better. :)

  • Developer

Yes, I see your point with enabling all causing trouble. I agree. I was just in a *****y mood, so don't lose any sleep over mod enabling. :p

Hey, no worries! I definitely want to know what things you find frustrating, as many people will find them frustrating but won't have your tenacity and willingness to report the problem. I can't always promise a perfect solution but I'd sure like to try!

[MENTION=55]Ipsquiggle[/MENTION]Is there any way to offset an AnimState? I'm working on a prefab mod that would take the Spider Queen as a base, but with the modded creature having no legs (walking on its torso, it's a gastropod), and I haven't really found a way for it to not float. Even disabling physics collision and trying to move the entity into the ground didn't look quite right (since the map is really an "underlay" and not an actual plane in space).---edit---Well, I suppose the Physics trick could be made to look right by "outsourcing" the generation of shadows to a dummy child prefab (and have it follow the torso symbol, or something like that). But I'd like to avoid changing the Y coordinate of the actual prefab, since the game will often assume prefabs on the ground have a 0 Y coordinate, so that I'd have to wrap the inst.Transform metatable in an adapter that does the offsetting transparently. And I could also outsource the physics collision to another child entity (or maybe the same one). However, I'm hoping there's a cleaner way of doing that. The Spider Queen anims are too good to be abandoned.

Edited by simplex
  • Developer

Actually, my first instinct for doing this would be to have two entities, one parented to the other. The parent one would handle basically everything, and the child basically contains the animation. This would probably get pretty ugly in terms of passing along animation/state stuff, but our anim components are closely tied to the transform so there's no easy way to offset the graphic.

Actually, my first instinct for doing this would be to have two entities, one parented to the other. The parent one would handle basically everything, and the child basically contains the animation. This would probably get pretty ugly in terms of passing along animation/state stuff, but our anim components are closely tied to the transform so there's no easy way to offset the graphic.

Thanks, I'll try that.

What would be the best way to have the child entity follow the parent one? child.entity:AddFollower():FollowSymbol()?

And if I just did parent.AnimState = child.AnimState to translate the animation calls, would this cause issues on entity deconstruction?

---edit---

Sorry, of course FollowSymbol() would not work, since the parent entity would not have animation symbols to be followed. :p

How could I accomplish this, then?

---edit 2---

Is there a dummy animation bank/build with just an invisible animation symbol?

And about the possible deallocation issues, I'm guessing there are none, since inst:Remove() will only make the "real" entity retire, and it presumably would only have a reference to a AddAnimState() added AnimState (if you'll pardon my verbal redundancy :p).

---edit 3---

Nevermind about the "issue" on the child entity following the parent one. I didn't know that was granted already. :p

Edited by simplex
  • Developer

Yes, just to reiterate your discoveries for clarity.. :)

 

You can add a child with entity:AddChild(child_ent). This links the transforms, and causes :SetPosition() calls on the child to become relative to the parent.

 

:Remove() will only remove the specific entity, so you'll have to remove the child as well.

 

By not calling :AddAnimState() an entity will simply have no animation. In fact this could be a sneaky way to highjack the existing stategraphs etc, by adding a fake anim state to the entity which forwards all its calls to its child....

Yes, just to reiterate your discoveries for clarity.. :-) You can add a child with entity:AddChild(child_ent). This links the transforms, and causes :SetPosition() calls on the child to become relative to the parent. :Remove() will only remove the specific entity, so you'll have to remove the child as well. By not calling :AddAnimState() an entity will simply have no animation. In fact this could be a sneaky way to highjack the existing stategraphs etc, by adding a fake anim state to the entity which forwards all its calls to its child....

Well, I managed to get the animation to touch the ground through the following (though the actual offsetting still needs some tweaking):
--[[/*-- Returns a function which receives the parent and child entities, returning-- a virtualized Transform for the parent.---- Receives an array with the methods to be ran on the child Transform before-- the corresponding ones are ran on the parent one.*/--]]local function NewTransformVirtualizer( translated_methods )	local unique_key = {}	local translation_set = {}	for _, k in ipairs(translated_methods) do		translation_set[k] = true	end	local function override_self(method, self_override)		return function(self, ...)			return method(self_override, ...)		end	end		local meta = {		__index = function(t, k)			--// metadata stores the Transform userdata for the parent and child.			local metadata = t[unique_key]			local v = metadata.parent[k]			if type(v) == "function" then				local parent_method = override_self(v, metadata.parent)				local child_method = translation_set[k] and metadata.child[k]				if type(child_method) == "function" then					child_method = override_self(child_method, metadata.child)					v = function(_, ...)						child_method(nil, ...)						return parent_method(nil, ...)					end				else					v = parent_method				end			end			--// Caches the result.			t[k] = v			return v		end,	}	return function(parent, child)		local pT = assert( parent.Transform )		local cT = assert( child.Transform )		local T = {			[unique_key] = {				parent = assert( parent.Transform ),				child = assert( child.Transform ),			},		}		return setmetatable(T, meta)	endend--[[/*-- Receives the parent and child entities, as well as the positional offset.---- Returns the new Transform field for the parent.*/--]]local VirtualizeTransform = NewTransformVirtualizer {"SetRotation"}local function CreateAnimationChild(parent, anim_offset)	assert( parent:is_a(EntityScript) )	assert( anim_offset:is_a(Point) )	--//assert( not parent.AnimState )	local child = CreateEntity()	child.entity:AddTransform():SetFourFaced()	--// Adding physics is required for everything to work properly.	child.entity:AddPhysics()	child.entity:AddAnimState()	child.Transform:SetPosition(anim_offset:Get())	parent:AddChild(child)	parent.animchild = child	parent.AnimState = child.AnimState	child.components = parent.components	parent.Transform = VirtualizeTransform(parent, child)		function child:PushEvent(...)		return parent:PushEvent(...)	end	return childend	local function fn(Sim)	local CONFIG = TUNING.SNAILKING	local inst = CreateEntity()	inst.entity:AddTransform()	inst.entity:AddAnimState()	inst.AnimState:SetBank("stinger")	inst.AnimState:SetBuild("stinger")	inst.AnimState:PlayAnimation("idle")		local animchild = CreateAnimationChild(inst, Point(-1, -2, 0))	local anim = inst.AnimState	anim:SetBank("spider_queen")	anim:SetBuild("snailking")	anim:PlayAnimation("idle", true)	--//anim:SetSortOrder(1)	--[[/*  stuff  */]]--
(I apologize for the bright colors that sometimes hinder readability. The "nocode" option of the "code" BBCode is not working. I tweaked the comments to make things more readable.)
By my testings, I had to add a dummy AnimState to the parent entity, otherwise sometimes it would lock up. I'm using "stinger" as a placeholder, since it's the simplest build in the game files, but using a duplicate snailking build with an empty texture would be better further on.However, this introduced a few nasty problems. Namely, depth testing is waaay off, and the entity is not clickable. On what is the "click region" of an entity based on, its (unscaled) AnimState, its Physics or something else entirely? Is there a way to change an entity "radius" in relation to that?Because of those issues, I feel I won't be able to offset the animation smoothly. At best, I'd be able to get it in a "ok" state. So I think I should really drop the idea of using the Spider Queen as a base. However, if you could answer some of these questions I'd appreciate it, nevertheless.EDIT
Ha! I found a clever way to disable highlighting (but I'll keep the previous snippet as is, since for its most part the highlighting is not that off, it's just the colors that could be more readable):
<<<EOSfunction unhighlighted()	print "Gray scale!"end
Edited by simplex
@Ipsquiggle, I've managed to get most of the new pointers to where all the screen files are (widgets) for Test Tools testscreen.lua:
local Widget = require "widgets/widget"require("util")local Screen = require "widgets/screen"require("widgets/button")require("widgets/animbutton")local Image = require("widgets/image")require("widgets/uianim")local Spinner = require("widgets/spinner")local Numericspinner = require("widgets/numericspinner")require("screens/popupdialog")require("widgets/textbutton")require("widgets/toggle")local Keyscreen = require("screens/keyscreen")local build_info = require "testtools.builds"local spinner_atlas = "images/ui.xml"
Took many tries to even get Test Tools to load in the preview, but now it does. When I hit F1 to load testscreen, I get a background, but no controls at all.
 
The relevant log text points to 'gsub' in util.lua:
 
Any thoughts?
 
...m/steamapps/common/dont_starve/data/scripts/util.lua:251: bad argument #1 to 'gsub' (string expected, got table)
LUA ERROR stack traceback:
        =[C] in function 'gsub'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/util.lua(251,1) in function 'resolvefilepath'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/image.lua(27,1) in function 'SetTexture'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/image.lua(11,1) in function '_ctor'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'Image'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/threeslice.lua(13,1) in function '_ctor'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'ThreeSlice'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/spinner.lua(51,1) in function '_ctor'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'Spinner'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/screens/testscreen.lua(548,1) in function 'DoInit'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/screens/testscreen.lua(388,1) in function '_ctor'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'TestScreen'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/components/testtoolcontroller.lua(23,1) in function 'ToggleMenu'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/components/testtoolcontroller.lua(80,1) in function 'fn'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/events.lua(46,1) in function 'HandleEvent'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/input.lua(89,1) in function 'OnRawKey'
        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/input.lua(205,1)
C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/frontend.lua(388,1) SCRIPT ERROR! Showing error screen 
C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/mods.lua(280,1) unloading prefabs for mod MOD_Test Tools
Edited by tehMugwump
  • Developer

@Ipsquiggle, I've managed to get most of the new pointers to where all the screen files are (widgets) for Test Tools testscreen.lua: 

local Widget = require "widgets/widget"require("util")local Screen = require "widgets/screen"require("widgets/button")require("widgets/animbutton")local Image = require("widgets/image")require("widgets/uianim")local Spinner = require("widgets/spinner")local Numericspinner = require("widgets/numericspinner")require("screens/popupdialog")require("widgets/textbutton")require("widgets/toggle")local Keyscreen = require("screens/keyscreen")local build_info = require "testtools.builds"local spinner_atlas = "images/ui.xml"

 All the widgets should be exporting a single class now, so anything in the widgets folder requires that assignment to local, e.g. UIAnim, TextButton, etc. Doing that should cover mostly everything... 

Took many tries to even get Test Tools to load in the preview, but now it does. When I hit F1 to load testscreen, I get a background, but no controls at all. The relevant log text points to 'gsub' in util.lua: Any thoughts? 

...m/steamapps/common/dont_starve/data/scripts/util.lua:251: bad argument #1 to 'gsub' (string expected, got table)LUA ERROR stack traceback:        =[C] in function 'gsub'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/util.lua(251,1) in function 'resolvefilepath'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/image.lua(27,1) in function 'SetTexture'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/image.lua(11,1) in function '_ctor'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'Image'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/threeslice.lua(13,1) in function '_ctor'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'ThreeSlice'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/widgets/spinner.lua(51,1) in function '_ctor'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'Spinner'        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/screens/testscreen.lua(548,1) in function 'DoInit'        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/screens/testscreen.lua(388,1) in function '_ctor'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/class.lua(28,1) in function 'TestScreen'        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/components/testtoolcontroller.lua(23,1) in function 'ToggleMenu'        C:/Program Files/Steam/steamapps/common/dont_starve/data/../mods/Test Tools/scripts/components/testtoolcontroller.lua(80,1) in function 'fn'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/events.lua(46,1) in function 'HandleEvent'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/input.lua(89,1) in function 'OnRawKey'        C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/input.lua(205,1)C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/frontend.lua(388,1) SCRIPT ERROR! Showing error screen C:/Program Files/Steam/steamapps/common/dont_starve/data/scripts/mods.lua(280,1) unloading prefabs for mod MOD_Test Tools

If you look at the signature for Spinner (spinner.lua line 31) it has 7 possible parameters. It's the atlas, the 6th parameter, which is screwing up. Make sure that in testscreen.lua line 548 that the atlas is in fact in the 6th parameter slot?

 

If you're not supplying the atlas or textures list at all, then something is screwey and I can look further into it.

 All the widgets should be exporting a single class now, so anything in the widgets folder requires that assignment to local, e.g. UIAnim, TextButton, etc. Doing that should cover mostly everything... 

If you look at the signature for Spinner (spinner.lua line 31) it has 7 possible parameters. It's the atlas, the 6th parameter, which is screwing up. Make sure that in testscreen.lua line 548 that the atlas is in fact in the 6th parameter slot?

 

If you're not supplying the atlas or textures list at all, then something is screwey and I can look further into it.

The frustrating part is not knowing what all changed and having to blindly poke around in the dark (not your problem, I know)

 

Moving the atlas to the 6th slot looks like it got the buttons showing, but they're now all off screen.  Just a corner of one is showing in the lower left corner.  

 

My set up mirrors the setup in the OLD customizationscreen:

testscreen -self.itemSpinner = Spinner(uncraftableItemOptions, 180, spinnerHeight, spinnerFont, spinner_atlas, spinner_images)customizationscreen - opt:AddChild(Spinner( spin_options, w, spin_height, spinfont, spinner_atlas, spinner_images ))

I also see that a lot's changed from the old customizationscreen.lua to the new:

Things like:

from:

local presetspinnerFont = { font = BUTTONFONT, size = 30 }local w = 200self.presetspinner = self.presetpanel:AddChild(Spinner( self.presets, w, 50, presetspinnerFont, spinner_atlas, spinner_images ))self.presetspinner:SetPosition(-self.presetspinner:GetWidth()/2, 50, 0)

to:

local w = 400self.presetspinner = self.presetpanel:AddChild(Spinner( self.presets, w, 50))self.presetspinner:SetPosition(0, 50, 0)

Hell, in the new customization.lua they aren't even using things like spinner_atlas now.

 

I'll return to spelunking... or maybe just go play Spelunky instead.

 

On a lighter note, I got Personal Backpack and Amulet working for Nightmares.  Serious UI changes there.

Edited by tehMugwump

Ipsquiggle,When using Matt's BuildRenamer to rename the Beefalo build, I noticed it erased the listing of animation symbols at the end of build.bin. Would this prevent their usage, say, in symbol overrides?And in order to rename them, is editing build.bin (adjusting also the 4 bytes preceding each, which list their name lengths as a 32-bit integer) enough, or would every relevant anim.bin require editing as well? (I'm guessing not, since otherwise Matt's tool wouldn't work, but I feel I should ask anyway)

Edited by simplex

Would you be willing to share the format of the save games with us? :)

 

While the library I have been working on is able to read them just fine, I have not yet managed to save them to disk in a way which allows Don't Starve to load the save game once more.

IpsquiggleAgain, a question based on Matt's tools. When premultiplying alpha to generate a TEX, shouldn't the alpha channel be set to 255, instead of preserving it? Isn't the desired behaviour to have it blended over an opaque, black background?EDIT


And oh yes, in my previous post, when I said 32-bit integer it should be 8-bit. I got thrown off by the 3 preceding bytes always being 0, but I don't suppose it would adopt a Big Endian representation. Edited by simplex
  • Developer

 

The frustrating part is not knowing what all changed and having to blindly poke around in the dark (not your problem, I know)

 

 

Have you ever used a tool like WinMerge? If you make a copy of the scripts folder before updating to the preview branch, and then compare the two, it will show you exactly what's changed. I know this is not really what you're asking for, but I do find it a useful technique for spotting smaller differences especially.

 

Regarding the spinners specifically, they've had a few changes under the hood, but I think the main thing you'll be concerned about is that they now provide defaults for most of their parameters.

 

 

 

Ipsquiggle,When using Matt's BuildRenamer to rename the Beefalo build, I noticed it erased the listing of animation symbols at the end of build.bin. Would this prevent their usage, say, in symbol overrides?And in order to rename them, is editing build.bin (adjusting also the 4 bytes preceding each, which list their name lengths as a 32-bit integer) enough, or would every relevant anim.bin require editing as well? (I'm guessing not, since otherwise Matt's tool wouldn't work, but I feel I should ask anyway)

 

The name which buildrename affects is the name of the build itself, which must be unique, so altering that one file should be sufficient. Anims don't know anything about the builds that get loaded on them.

 

 

 

Would you be willing to share the format of the save games with us? :-)

 

While the library I have been working on is able to read them just fine, I have not yet managed to save them to disk in a way which allows Don't Starve to load the save game once more.

 

I believe the game will load save files even if they are plain text (normally they are zipped and base64 encoded). When it's not compressed it should look just like normal lua code. Try saving that perhaps?

 

If not, our process is just to compress using zlib and standard base64 encoding (using + and / as the extra symbols).

 

 

 

IpsquiggleAgain, a question based on Matt's tools. When premultiplying alpha to generate a TEX, shouldn't the alpha channel be set to 255, instead of preserving it? Isn't the desired behaviour to have it blended over an opaque, black background?

 

Premultiply doesn't affect the alpha channel, only the RGB channels. (The operation is newrgb = oldrgb * alpha.)

The name which buildrename affects is the name of the build itself, which must be unique, so altering that one file should be sufficient. Anims don't know anything about the builds that get loaded on them.

Yes, but I was referring to the declaration of animation symbols at the end of it. In the Beefalo build, after renaming it all the following entries (as well as the 4 bytes preceding each) were removed:beefalo_bodybeefalo_nosebeefalo_antlerbeefalo_lip_creasebeefalo_facebasebeefalo_tailbeefalo_headbasebeefalo_beardbeefalo_eyebeefalo_jowlsbeefalo_hoofbeffalo_lipsbeefalo_mouthmouthIs this really a non-issue? 

Premultiply doesn't affect the alpha channel, only the RGB channels. (The operation is newrgb = oldrgb * alpha.)

But then how does the game differentiate between premultiplied textures and otherwise? Or does it just assume all textures have been premultiplied?
  • Developer

Yes, but I was referring to the declaration of animation symbols at the end of it. In the Beefalo build, after renaming it all the following entries (as well as the 4 bytes preceding each) were removed:beefalo_bodybeefalo_nosebeefalo_antlerbeefalo_lip_creasebeefalo_facebasebeefalo_tailbeefalo_headbasebeefalo_beardbeefalo_eyebeefalo_jowlsbeefalo_hoofbeffalo_lipsbeefalo_mouthmouthIs this really a non-issue? But then how does the game differentiate between premultiplied textures and otherwise? Or does it just assume all textures have been premultiplied?

 

Whoops sorry, I misread your original post.

 

The list at the end of the file is a mapping of ID -> Symbolname. It's not actually used by the engine, it was specifically put there to assist modders with reverse-converting the files. If it's missing the files will still load fine.

 

And yes, the game assumes premultiplied; that's how all our textures are converted. 

Whoops sorry, I misread your original post. The list at the end of the file is a mapping of ID -> Symbolname. It's not actually used by the engine, it was specifically put there to assist modders with reverse-converting the files. If it's missing the files will still load fine.And yes, the game assumes premultiplied; that's how all our textures are converted.

Thanks for the info, I appreciate it. (:

Have you ever used a tool like WinMerge? If you make a copy of the scripts folder before updating to the preview branch, and then compare the two, it will show you exactly what's changed. I know this is not really what you're asking for, but I do find it a useful technique for spotting smaller differences especially.

Thanks, yeah, I've been using NotePad ++ with the compare plugin to do just that.  It's saved my arse more than once.

I know this isn't the place for this, but I've been having a crash that claims to be a mod related crash when I have no mods enabled or even installed, it happened both in the current build and the August 20th Preview, so far no one is really taking much interest, Wade made not of my report but I'd like to leave a link to my official Bug report here just so more people, perhaps people more inclined with mods, could take a look at the crash logs and see what the issue is besides a buggy Mod registry.

 

Links Ahoy!

If you're puzzling out the file formats, there a few helpful links:

 

The pipeline producing the files (and showcasing the format):

http://forums.kleientertainment.com/index.php?/topic/18664-qusestion-animation-files-and-custom-characters/?hl=pipeline#entry176834

 

A sample XML:

http://forums.kleientertainment.com/index.php?/topic/21111-creating-an-anim-for-items-on-the-ground/#entry210493

 

Granted, I spent time figuring out the raw binary before I saw those posts - not the easiest to find, even when I knew what i was looking for. But ti sure helped me name stuff in the text files.

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...