边缘世界 RimWorld

边缘世界 RimWorld

Realistic Lighting and Shadows
Maal 7 月 17 日 下午 5:53
Bug report
Creating a post to properly send the error text in one message and not 2-3 comments.

Sorry if it ain't this mod, but since it the error mention planet tilt, sun direction and colors, it MIGHT be this lol. The error appear right after arriving on the map when starting a new colony.

log:
https://gist.github.com/HugsLibRecordKeeper/ea71116983af823d66e3d8182d2a9bd1

Cannot use Graphic_Random.GetColoredVersion with a non-white colorTwo. UnityEngine.StackTraceUtility:ExtractStackTrace () (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch3 (string) Verse.Log:ErrorOnce (string,int) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Graphic_Random.GetColoredVersion_Patch1 (Verse.Graphic_Random,UnityEngine.Shader,UnityEngine.Color,UnityEngine.Color) Verse.GraphicData:GraphicColoredFor (Verse.Thing) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Thing.get_DefaultGraphic_Patch1 (Verse.Thing) Verse.Thing:get_Graphic () Verse.Thing:Print (Verse.SectionLayer) Verse.ThingWithComps:Print (Verse.SectionLayer) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.SectionLayer_ThingsGeneral.TakePrintFrom_Patch1 (Verse.SectionLayer_ThingsGeneral,Verse.Thing) System.Reflection.RuntimeMethodInfo:Invoke (object,System.Reflection.BindingFlags,System.Reflection.Binder,object[],System.Globalization.CultureInfo) System.Reflection.MethodBase:Invoke (object,object[]) RealTiltMod.Patch_SectionLayerThings_Regenerate_On_Sun_Direction_Change:Prefix (object) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.SectionLayer_Things.Regenerate_Patch1 (Verse.SectionLayer_Things) Verse.Section:RegenerateAllLayers () Verse.MapDrawer:RegenerateEverythingNow () Verse.Map:<FinalizeInit>b__198_0 () Verse.LongEventHandler:ExecuteToExecuteWhenFinished () Verse.LongEventHandler:UpdateCurrentAsynchronousEvent () Verse.LongEventHandler:LongEventsUpdate (bool&) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Root.Update_Patch1 (Verse.Root) (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Root_Play.Update_Patch1 (Verse.Root_Play)
最后由 Maal 编辑于; 7 月 17 日 下午 5:54
< >
正在显示第 1 - 11 条,共 11 条留言
Sjaandi  [开发者] 7 月 17 日 下午 9:40 
Thank you! I think I've narrowed down where this is coming from.
Other than this warning - is it interrupting your play at all?
Maal 7 月 17 日 下午 9:57 
To be honest this is only 1 of several dozens red error my modlist currently gives (Mostly compatibility patches relying on changed code from other mods that weren't properly updated to 1.6 I'd guess). So I haven't played a real playthrought yet, and couldn't say if this mod was causing any actual any issue lol.
Sjaandi  [开发者] 7 月 20 日 下午 6:22 
So after more investigation, this is caused because the vanilla game doesn't handle colorTwo being set to a non-white color. I'm not doing any coloring on objects in the game, so the error is being thrown due to one of your other mods. It's a benign error so you can safely ignore it. At best the other mod author IS doing things correctly and the game is logging a hard-coded warning anyway, and at worst the game is just ignoring the other mod author's color choices and using vanilla behavior.
If you are able to figure out which mod is causing it - you could tell the mod author the error is caused because they are setting colorTwo on a Graphic_Random object to a non-white color, and vanilla automatically checks for that exact condition and logs an error if its true.
Maal 7 月 20 日 下午 7:01 
I did a folder wide search of my mod list and found 760 instances of colortwo to a non-white color. in dozens of mods. So maybe there is a proper way to do this and that one instance did it wrong... In any case, thanks you for looking into this even if your mod wasn't at fault.
Sjaandi  [开发者] 7 月 20 日 下午 7:11 
The error is for Graphic_Random objects. Other types of objects are fine having their colorTwo set to a non-white color.
Maal 7 月 20 日 下午 7:36 
Yeaah, after I checked colortwo I also checked that one and had a few thousands hit. But since you said it was benign I decided that I would save myself a few hours and headache and wait until I saw an actual in-game problem as I'm not sure I can filter these search efficiently to find any linked to colortwo and I ain't going to open each of these thousand of result by hand lol.
Sjaandi  [开发者] 7 月 20 日 下午 7:40 
No kidding. As long as the error doesn't keep popping up incessantly (annoying) you should be good. The reason my mod made it noticeable is because it forces a redraw every time the sun rotates 90 degrees (2D plane) in order to prevent shadows from overlapping incorrectly. So while that doesn't cause the error, it does make it more noticeable as it will repeat instead of just happening once on map load.
Game's now freaking out when taking off in the gravship
```Exception from long event: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 7F61430A]
at PipeSystem.PipeNetManager.UnregisterConnector (PipeSystem.CompResource comp) [0x000ce] in <51e70c54d3a74897b386f0d6bd1f0d95>:0
at PipeSystem.CompResource.PostDeSpawn (Verse.Map map, Verse.DestroyMode mode) [0x00007] in <51e70c54d3a74897b386f0d6bd1f0d95>:0
at PipeSystem.CompPipeValve.PostDeSpawn (Verse.Map map, Verse.DestroyMode mode) [0x00001] in <51e70c54d3a74897b386f0d6bd1f0d95>:0
at Verse.ThingWithComps.DeSpawn (Verse.DestroyMode mode) [0x00032] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
- PREFIX realtiltmod: Void RealTiltMod.Patch_SunLamp_DeSpawn:Prefix(ThingWithComps __instance)
at Verse.Building.DeSpawn (Verse.DestroyMode mode) [0x0000e] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
at RimWorld.GravshipUtility.GenerateGravship (RimWorld.Building_GravEngine engine) [0x000ae] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
at Verse.WorldComponent_GravshipController.RemoveGravshipFromMap (RimWorld.Building_GravEngine engine) [0x00014] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
at Verse.WorldComponent_GravshipController+<>c__DisplayClass43_0.<OnGravshipCaptureComplete>b__2 () [0x00060] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
at Verse.LongEventHandler.UpdateCurrentSynchronousEvent (System.Boolean& sceneChanged) [0x0001d] in <d2f9716cc2ac4cda9c2a174cc147bf37>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch1 (string)
Verse.LongEventHandler:UpdateCurrentSynchronousEvent (bool&)
Verse.LongEventHandler:LongEventsUpdate (bool&)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Root.Update_Patch1 (Verse.Root)
Verse.Root_Play:Update ()
```
Sjaandi  [开发者] 7 月 26 日 下午 10:47 
Do you have the latest version of the mod? (4.3 - can find it in mod settings under "show Changelog Popup again").
I removed that method in the last hotfix - so it shouldn't even exist.
Bazalisk 10 月 10 日 下午 6:53 
i'm getting this:

```
Exception from long event: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 6282ED61]
at RealTiltMod.Patch_ReplaceSunLayer.Postfix (Verse.Section __instance) [0x00054] in C:\Users\Ryan\source\repos\RealTiltMod\RealTiltMod\Shadows\SunShadows.cs:27
at Verse.Section..ctor (Verse.IntVec3 sectCoords, Verse.Map map) [0x00163] in <24d25868955f4df08b02c73b55f389fe>:0
- PREFIX ShipInteriorMod2: Boolean SaveOurShip2.SectionConstructorPatch:Prefix(Map map)
- POSTFIX realtiltmod: Void RealTiltMod.Patch_ReplaceSunLayer:Postfix(Section __instance)
- POSTFIX ShipInteriorMod2: Void SaveOurShip2.SectionConstructorPatch:Postfix(Map map, Section __instance, List`1 ___layers)
at SaveOurShip2.Setup+<>c.<.cctor>b__0_1 () [0x00009] in <171a6b1614ed449c835463680a64acb6>:0
at Verse.LongEventHandler.UpdateCurrentSynchronousEvent (System.Boolean& sceneChanged) [0x0001d] in <24d25868955f4df08b02c73b55f389fe>:0
Short hashes are saturated. There are probably too many Defs. (Repeated 99 times)
```

I have a Huge modlist and i'm not suprised that i'm having issues so its on me but thought it worth mentioning here anyway.
Sjaandi  [开发者] 10 月 11 日 上午 1:18 
I don't have SaveOurShip2. Can you describe what's happening when you get this bug?
< >
正在显示第 1 - 11 条,共 11 条留言
每页显示数: 1530 50