Ludeon Forums

RimWorld => Releases => Mods => Outdated => Topic started by: 1000101 on June 29, 2015, 04:18:48 PM

Title: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on June 29, 2015, 04:18:48 PM
(https://github.com/RimWorldCCLTeam/CommunityCoreLibrary/blob/master/WebGraphics/CCL_Logo_Long.png?raw=true)

This is the old forum thread, please redirect yourself to the new thread here (https://ludeon.com/forums/index.php?topic=16599.0).
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: skullywag on June 29, 2015, 04:20:49 PM
you got the coloured light thing working....gimee nomnomnom...
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: 1000101 on June 29, 2015, 04:25:13 PM
:)

Just add CCLs ThingComp to your lights.  It will mean your mod now depends on CCL, but that is the point of CCL.  :)
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: Loki88 on June 29, 2015, 04:58:20 PM
This changes EVERYTHING! Now to get my brain to figure out how to use it... *notices smoke coming from ears*
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: skyarkhangel on June 29, 2015, 06:01:15 PM
Low Idle Power (ThingComp) - Allows tables which shouldn't use power when not in use to draw less.

wow.. big thanks especially for it!


1000101, can you make with this.. Placement restrictions (PlaceWorkers) "Only on smoothed floor?
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: 1000101 on June 29, 2015, 07:01:38 PM
Quote from: skyarkhangelLow Idle Power (ThingComp) - Allows tables which shouldn't use power when not in use to draw less.

wow.. big thanks especially for it!
Yeah, it bothered me when my colonists would go to bed and leave the stove on.  :\

Quote from: skyarkhangel1000101, can you make with this.. Placement restrictions (PlaceWorkers) "Only on smoothed floor?
It's possible, I'll look into it.  Thanks for the suggestion, always looking to improve on this and add functionality which will help everyone.
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: skyarkhangel on June 29, 2015, 07:10:12 PM
Quote from: 1000101 on June 29, 2015, 07:01:38 PM
Quote from: skyarkhangelLow Idle Power (ThingComp) - Allows tables which shouldn't use power when not in use to draw less.

wow.. big thanks especially for it!
Yeah, it bothered me when my colonists would go to bed and leave the stove on.  :\

Quote from: skyarkhangel1000101, can you make with this.. Placement restrictions (PlaceWorkers) "Only on smoothed floor?
It's possible, I'll look into it.  Thanks for the suggestion, always looking to improve on this and add functionality which will help everyone.

And that class could works with terraindefs too..? Eg.. Needs to smooth floor before build woodenfloor or other floors.
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: 1000101 on June 29, 2015, 08:33:14 PM
While I can probably get a place worker restriction for smooth floors, I'm not sure I would put it in CCL that flooring requires floors to be smoothed first.  That part sounds like it would be good for a separate mod though.  I don't want to "inflict" too much on the user with the core of CCL, that's where other mods come in which make use of CCLs available resources.

In the full source download for CCL is an example of a refrigerated meal shelf.  I didn't put this into the main user download as I'm not aiming on adding directly to RimWorld content with CCL but provide tools for modders not to have to re-invent the wheel all the time.  What is modded in CCL from the vanilla is only the core assets which would make sense to use the new functionality (such as production tables and auto-doors using CompPowerLowIdleDraw and the lamps being resolved into a single entity using CompColoredLight).
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: Loki88 on June 29, 2015, 08:49:55 PM
Is the <CompColoredLight> limited to the standard red green and blue of vanilla or is it possible to define your own custom colours within the mod using this tag? Ie, if I were to make a version of my LED rope lights mod to use this can I implement it to use the gold and violet colours I currently have?
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: 1000101 on June 29, 2015, 09:22:02 PM
CompColoredLight has it's own set of colors defined but you can define your own.  If you don't define your own it uses the predefined colors.  CompProperties_ColoredLight.cs (https://github.com/ForsakenShell/CommunityCoreLibrary/blob/master/DLL_Project/CompProperties/CompProperties_ColoredLight.cs) is the colored light properties.

Default colors:
white, ( 217, 217, 217,   0 )
red, ( 217,   0,   0,   0 )
green, (   0, 217,   0,   0 )
blue, (   0,   0, 217,   0 )
yellow, ( 217, 217,  43,   0 )
orange, ( 255, 132,   0,   0 )
purple, ( 185,  61, 205,   0 )


How to define a light with only two custom colors:
<li Class="CommunityCoreLibrary.CompProperties_ColoredLight">
<compClass>CommunityCoreLibrary.CompColoredLight</compClass>
<color>
<li>
<name>white</name>
<value>( 255, 255, 255, 0 )</value>
</li>
<li>
<name>pukey pink</name>
<value>( 255, 0, 255, 0 )</value>
</li>
</color>
</li>


You can use <Default> (default 0) in the comp to specify the default color index.  You can also specify the research required to change color using <requiredResearch> (default "ColoredLights").

Don't forget you still need a CompGlower to define the radius and a CompPowerTrader.  If people demand it, the requirement for CompPowerTrader can become optional.
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: Loki88 on June 29, 2015, 10:17:44 PM
Quote from: 1000101 on June 29, 2015, 09:22:02 PM
CompColoredLight has it's own set of colors defined but you can define your own.  If you don't define your own it uses the predefined colors.  CompProperties_ColoredLight.cs (https://github.com/ForsakenShell/CommunityCoreLibrary/blob/master/DLL_Project/CompProperties/CompProperties_ColoredLight.cs) is the colored light properties.

Default colors:
white, ( 217, 217, 217,   0 )
red, ( 217,   0,   0,   0 )
green, (   0, 217,   0,   0 )
blue, (   0,   0, 217,   0 )
yellow, ( 217, 217,  43,   0 )
orange, ( 255, 132,   0,   0 )
purple, ( 185,  61, 205,   0 )


How to define a light with only two custom colors:
<li Class="CommunityCoreLibrary.CompProperties_ColoredLight">
<compClass>CommunityCoreLibrary.CompColoredLight</compClass>
<color>
<li>
<name>white</name>
<value>( 255, 255, 255, 0 )</value>
</li>
<li>
<name>pukey pink</name>
<value>( 255, 0, 255, 0 )</value>
</li>
</color>
</li>


You can use <Default> (default 0) in the comp to specify the default color index.  You can also specify the research required to change color using <requiredResearch> (default "ColoredLights").

Don't forget you still need a CompGlower to define the radius and a CompPowerTrader.  If people demand it, the requirement for CompPowerTrader can become optional.

Thank you very much for your explanation! All I could think of with removing power trader is technicolor camp fires and tiki torches  :P
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: mrofa on June 30, 2015, 09:47:15 AM
That is awsome thanks alot 1000101!
And that wall attachment damn i was just thinkering on it :D
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: sky on June 30, 2015, 11:47:31 AM
That should be included in Core. Would help a lot. ;)
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: mipen on July 01, 2015, 02:06:09 AM
How on earth did I gloss over this...? This is amazing! :P I'm definitely going to add this as a reference for MD2. Does the CompPowerTrader in this override the core one, or do you need to explicitly use it in the defs? And if so, is this done by CCL?

Also, another idea for a place worker would be to have one the limits the number of buildings of a type that can be built. If its possible, you could have that number defined in a def.

Anyways, some great work here :D
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: 1000101 on July 01, 2015, 02:32:21 AM
@mipen:

The core of CCL overrides the vanilla tables, you can take a look at those defs for a basic reference.

The low idle draw comp relies on there being a power trader and if the building also has a glower it will turn it off when going into low power mode.
Title: Re: [A11] Community Core Library (v0.11.0)
Post by: Leucetius on July 01, 2015, 04:05:52 PM
Very nice! Thank you - I already have some use for it. Everything practicable has lowPower Module and I'm building something fancy ;)

edit: aaaand I hit a wall which I can't circumvent without additions and modifications. Time to register with github :/


edit2: and bug report. As can be seen on the attached screenshot...
- powerUsage = -0.01
- glowOn = True
- curUser = null

Owens is smelting sand to glas for free right now...
Most likely connected: glowOn stays true even after the 500 ticks (always)

edit3: (I should go to bed) found it. You added a default tickerType Normal to every production building. Which a) makes sense (how would the prod-table know that there is someone working at it, if it weren't ticking) but b) may lead to unneccessary lag in late game because of all the ticking. Changed that at my end - only the powered tables ticking now. But that's a xml thing and can be done to everybodys liking by themselves.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: 1000101 on July 01, 2015, 11:48:32 PM
Although it uses a normal ticker, they don't do their checks every tick and I've tried to short-circuit everything I could to run less code.

The checks are only done on very few ticks.  Doors check every 30 ticks while in low power mode and not again until they have time to fully open and close (which is anywhere between 30-400 ticks depending on the stuff used for the door), work tables go 500 ticks between any checks when in full power mode, etc.

I've tried to keep things like that down so it doesn't lag.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: mrofa on July 05, 2015, 06:25:54 AM
How to use this place workers in xml or if the even got the xml hooks?
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: 1000101 on July 05, 2015, 01:19:40 PM
Download the source package and look into "Modders Resource."

It contains examples of things not covered in the core changes.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: mrofa on July 05, 2015, 01:46:31 PM
I figure it out, there was no example for place workers.
But i got kinda a problem thrugh im not sure if its a bug or intended, WallAttachment is this intended to build only next to walls and not on walls ?
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: kaptain_kavern on July 05, 2015, 02:05:01 PM
For building on wall i think it's like that :
<canPlaceOverWall>true</canPlaceOverWall>
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: 1000101 on July 05, 2015, 02:27:35 PM
@mrofa, PlaceWorker Examples (https://github.com/ForsakenShell/CommunityCoreLibrary/tree/master/_Mod/Modders%20Resource/PlaceWorkers/PlaceWorker_Restrictions)

Yeah WallAttachment is for things which attach to the side of a wall.  For things which go into walls, I have a new place worker for the next release which can handle that by specifying what ThingDefs it can (or can not) be placed on.

@kaptain_kavern,

As long as your building isn't an edifice (isEdifice is false), you can build it on a wall (or any other building). canPlaceOverWall is for replacing the wall with your new ThingDef such as doors.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: mrofa on July 05, 2015, 02:33:42 PM
Quote from: 1000101 on July 05, 2015, 02:27:35 PM
@mrofa, PlaceWorker Examples (https://github.com/ForsakenShell/CommunityCoreLibrary/tree/master/_Mod/Modders%20Resource/PlaceWorkers/PlaceWorker_Restrictions)

Yeah WallAttachment is for things which attach to the side of a wall.  For things which go into walls, I have a new place worker for the next release which can handle that by specifying what ThingDefs it can (or can not) be placed on.

@kaptain_kavern,

As long as your building isn't an edifice (isEdifice is false), you can build it on a wall (or any other building).

Thanks mate, im just actually writing one for walls,but when ccl is up gona switch to yours since it will most likley look more sane then my current :D

Edit: also when i use place worker it seems that the interaction cells dont get thier checks so you might consider that :P
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: 1000101 on July 05, 2015, 03:29:02 PM
Quote from: mrofaEdit: also when i use place worker it seems that the interaction cells dont get thier checks so you might consider that :P

feature?   :o

I'll see if I notice anything strange with interaction cells though.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: kaptain_kavern on July 05, 2015, 05:18:01 PM
Thx for sharing the knowledge ;)
BTW is there a Wiki page or another resource with all (or some) tags explained?
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: 1000101 on July 05, 2015, 06:41:04 PM
Not at the moment.

I did do a doxygen on an earlier revision of the sources, but it was outdated and unless you are a coder, doxy files can be hard to follow.

There are some resources which are secondary (download the source version) which demonstrate some of the things not included directly into anything in the core mod.  ie, nothing from the core mod was updated to use placement restrictions but there is a "modders resource" showing how to use them.

Edit:

As of v0.11.3 the GeothermalGenerator now uses PlaceWorker_OnlyOnThing.
Title: Re: [A11] Community Core Library (v0.11.1)
Post by: hopeseekr on July 05, 2015, 08:22:52 PM
So this was never released for A10? :-/ This might be a good enough reason for me to upgrade. For some reason, I am horribly, terribly afraid of Sappers.
Title: Re: [A11b] Community Core Library (v0.11.2)
Post by: 1000101 on July 07, 2015, 06:57:46 PM
v0.11.2 Update

Update includes:

More PlaceWorker restrictions (by request),

On the surface:
Lights can share color information with handy gizmos,
Hydroponics can share growing information with handy gizmos

In the deep:
Lots of useful functionality added for modders looking to write C# code directly using CCL.  Open up the sources and have a look.

Modders references shows a fairly complete set of basic xml-only type things you can do.  At least, from the "how it works" perspective.  It's only otherwise limited by your ability to use these basic building blocks.
Title: Re: [A11b] Community Core Library (v0.11.2)
Post by: mrofa on July 09, 2015, 06:25:51 AM
Amazing stuff mate :D

I got a small problem thrugh, did some testing with WallAttachment place worker, as it turns out it will use many other buildings as support, like heaters or chairs
Title: Re: [A11b] Community Core Library (v0.11.2)
Post by: 1000101 on July 09, 2015, 11:23:36 AM
Yeah, it's more of an "isEdifice" attachment.  I'll look into what I can do about that for more clarity, etc.

I really don't like the idea of looking at specific def[names] for matches unless the modder can specify the list of defs.
Title: Re: [A11b] Community Core Library (v0.11.2)
Post by: mrofa on July 09, 2015, 12:54:09 PM
I think you can check traversability ,fillprocent and attlitudelayer. This should be engouh for most things
Title: Re: [A11b] Community Core Library (v0.11.2)
Post by: 1000101 on July 09, 2015, 04:48:42 PM
I took a look at what I can do about it and changed the code as follows:

            Building support = c.GetEdifice();
            if( ( support == null )||
                ( ( support.def.graphicData.linkFlags & ( LinkFlags.Rock | LinkFlags.Wall ) ) == 0 ) )
            {
                return "MessagePlacementAgainstSupport".Translate();
            }


So, if a building is an edifice AND links with walls or rock it's valid.  This generally only applies to walls and mineable rocks (not chunks) which is the intent.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: mipen on July 11, 2015, 04:36:26 AM
Hey 1000101, I was thinking of making a new def type that would let you change things in existing defs easily, to stop people having to overwrite the entire def. Would it be okay if I add it as a pull request to be merged with CCL?
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: 1000101 on July 11, 2015, 01:10:21 PM
Absolutely!

The whole idea of CCL is to be not just one persons code but generic redundant code from all for all.  I am actually thinking about removing the sunlamp building due to the fact that it's not overly generic and is more of a niche thing.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: jacob814 on July 23, 2015, 04:54:30 PM
I am a little annoyed unhappy with the colored lights approach. It may work with the vannila light but with mine modded lights, some of my colored lights have different attributes to them that make it not work. Example: the yellow/orange light has a comfort effect. I dont want this attribute for all lights.

Proposal. Make a categorized system like the stuff system, but for colors. This would give modders more room and compatibilty.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: 1000101 on July 23, 2015, 07:48:30 PM
Being "annoyed" with it is meaningless since there are lots of "annoying" things in the game.  If would like to see a change, can you elaborate on it?  What are you trying to and how are you doing it?  What do you think the comp should be doing and how should it do that?

I'm trying to keep things generic enough to work with any mod but specific enough as to not be useless.

tbh, I'm not sure how "comfort" applies to light given the context of comfort in the game (which seems to deal with physical comfort, not psychological comfort).
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: jacob814 on July 25, 2015, 09:20:45 PM
Point be taken with the comfort :)

This also applies to any other item as well. How about sub categories like the stuff sytem but something modders can use to create tehre own sub categories under a single assets.
Example: Instead of designating lights how you do now have it that once you have it colored light research, you can find the colored lights  in a list where standing lamp is located like how the stuff system works.
Another Example: lets say I want to have different recipes with my celing lights(dyed glass and such) but would like to keep them under the ceiling light button. Same as the stuff system does with walls and such.

This would of course only be so it would be easyer to navigate the menu. The system you have for colored lights could be kept but if you have it under a system like I described it would be quicker to find what you want with less button pressing, same with carpets. I need to point out that this system should not be limited to colors.

Another idea similiar to this is the possibilty to add more menu tabs. For example: instead of having my celing lights under furniture, I could create a new tab for lights. This is possible allready with some coding but I think that if this "Light category" was premade for this mod, my mod and advance lights mod could take advantage of this. Some other mods could like this as well if they desire.

I may have been harsh about being "annoyed". I just think this could be handled better for all modders. I feel like the way implimented now is restricting and could be worked apon. Thanks for the great mod.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: jacob814 on July 26, 2015, 03:29:23 PM
What am I doing wrong. I am trying use the advance research to have multiple research requirements for  a few buildings. It doesnt seem to be working. I am getting two errrors as well and as well stumped.


<?xml version="1.0" encoding="utf-8" ?>
<Defs>

<AdvancedResearchDef>

<defName>BuildColoredCeilingLamps<defName>
<Priority>1</Priority>

<researchDefs>
<li>ColoredLights</li>
<li>GlassworksResearch</li>
</researchDefs>

<buildingDefs>
<li>CeilingLampYellow</li>
<li>CeilingLampViolet</li>
<li>CeilingLampOrange</li>
<li>CeilingLampRed</li>
<li>CeilingLampGreen</li>
<li>CeilingLampBlue</li>
</buildingDefs>

</AdvancedResearchDef>

</Defs>



Error Log:
(http://puu.sh/jdMO6.jpg)
Sorry didnt know how to coppy the error log.

I know I am doing this wrong but I couldnt figure it out with the examples.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: 1000101 on July 26, 2015, 05:02:29 PM
You have not installed and activated CCL properly.

CCL MUST be installed and loaded.  DO NOT simply copy the DLL from CCL to your mod.  I can not stress this enough to people and it has come up a couple times.  Copying CCL in part or in whole to your mods directory WILL cause errors and possibly cause the earth to crash into the sun (you have been warned).

CCL users should be downloading "CCL_vx.y.z.zip" and installing as normal.

For modders, I recommend downloading the source package.  The source package requires you to copy "_Mod/Community Core Library" to your games mod directory and enable the CCL mod as normal.  The rest of the source package is all the reference materials to make mods for CCL.  For purely xml based mods, "_Mod/Modders Resource" [should] contains examples for everything which doesn't have a core mod tweak, ie, no modders resource for CompPowerLowIdleDraw.

If installed correctly as a user, modder or space pope, your modsConfig file should look something like this:<?xml version="1.0" encoding="utf-8"?>
<ModsConfigData>
    <buildNumber>nnn</buildNumber>
    <activeMods>
        <li>Core</li>
        <li>Community Core Library</li>
        <li>EVERYTHING ELSE</li>
    </activeMods>
</ModsConfigData>

Additionally you should see a line in your output log which reads "Community Core Library :: Advanced Research :: Initialized."
(Your RimWorld log file can be found in "RimWorldnnnPlatform_Data/output_log.txt".)

CCL is independent of everything except the Core mod and is designed to be upgraded independently.  This is so updates can automagically provide new features to existing CCL based mods without those mods also updating.  For example, since the first release CompColoredLight has a gizmo for changing the light color, v0.11.3 the same comp adds gizmos for sharing the color with other CompColoredLights and all the user has to do is update CCL to use them.

CCL is a mod like any other mod.  The only difference is it's intended purpose, aside from some basic vanilla core changes to take advantage of it's features; there is more than just an assembly (DLL) for CCL.  All* the files in the client package are required, there is nothing which is "optional."  The options come from other mods taking advantage of what CCL offers.

* Changes which are technically optional are changes to production tables (CompPowerLowIdleDraw) and the standing lamps (CompColoredLight), but who doesn't want those?

Edit:  Looking closer at your screen capture, it looks like you may have unzipped CCL into a parent zip directory name.  Check that it's unzipped correctly, the directory should be "Mods/Community Core Library", not "Mods/CommunityCoreLibrary-x.y.z"
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: jacob814 on July 26, 2015, 06:33:59 PM
I like how you have a copypast for this XD
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: jacob814 on July 26, 2015, 07:13:23 PM
My code still doesnt work even with the mod install correctly(facepalm)

<?xml version="1.0" encoding="utf-8" ?>
<Defs>

<AdvancedResearchDef>

<defName>BuildColoredCeilingLamps</defName>
<Priority>1</Priority>

<researchDefs>
<li>ColoredLights</li>
<li>GlassworksResearch</li>
</researchDefs>

<buildingDefs>
<li>CeilingLampYellow</li>
<li>CeilingLampViolet</li>
<li>CeilingLampOrange</li>
<li>CeilingLampRed</li>
<li>CeilingLampGreen</li>
<li>CeilingLampBlue</li>
</buildingDefs>

</AdvancedResearchDef>

</Defs>


the errors are gone though
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: 1000101 on July 26, 2015, 09:42:34 PM
Well, that xml looks correct and I am assuming at this point you are getting the CCL AR log message to indicate it's running.

Copy _Mod/Modders Resource/Advanced Research/Ancient Tech to your mods directory and enabling it.  That will hide the normal cryptosleep and allow you to build the ancient cryptosleep and demonstrates hiding and enabling buildings.  If that doesn't work, it would imply there is a bug in CCL.

I am using CCL 0.11.4 (not yet released) but nothing about the advanced research has changed so if you want to send me your mod I'll give it a test.  Perhaps there is a bug in CCL but I don't think so.
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: ypBwivc2aji6 on July 29, 2015, 12:49:00 PM
Hi,

I've been playing around with this, and given that the LowIdleDraw code already automatically turns glow on/off, I figured I start with something easy and make a motion activated light.

Community Core Library has been added to the Mods folder and is being loaded right after Core.

As I'm currently running the Ultimate Overhaul Modpack (V 1.0115),  I decided to use the "lighted wall" as a basis, making a copy of the xml, adding a few "motion" in the appropriate name and description elements, and adding both CompColoredLight and CompPowerLowIdleDraw to it.

The result looks like this:
<ThingDef ParentName="BuildingBase">
<defName>WallLightedMotion</defName>
<label>motion-activated lighted wall</label>
<thingClass>Building</thingClass>
<category>Building</category>
<description>A motion-activated lighted wall with a built in light.</description>
<graphicData>
<texPath>Things/Building/SCWalls/WallLights_Atlas</texPath>
<graphicClass>Graphic_Single</graphicClass>
<linkType>CornerFiller</linkType>
<linkFlags>
<li>Wall</li>
<li>Rock</li>
</linkFlags>
</graphicData>
<uiIconPath>Things/Building/SCWalls/WallLights_MenuIcon</uiIconPath>
<blueprintGraphicData>
<texPath>Things/Building/Linked/Wall_Blueprint_Atlas</texPath>
</blueprintGraphicData>
<statBases>
<MaxHitPoints>300</MaxHitPoints>
<WorkToMake>150</WorkToMake>
<Flammability>1.0</Flammability>
</statBases>
<leaveResourcesWhenKilled>false</leaveResourcesWhenKilled>
<altitudeLayer>BuildingTall</altitudeLayer>
<passability>Impassable</passability>
<castEdgeShadows>true</castEdgeShadows>
<fillPercent>1</fillPercent>
<coversFloor>true</coversFloor>
<placingDraggableDimensions>1</placingDraggableDimensions>
<tickerType>Normal</tickerType>
<rotatable>false</rotatable>
<selectable>true</selectable>
<neverMultiSelect>true</neverMultiSelect>
<terrainAffordanceNeeded>Heavy</terrainAffordanceNeeded>
<holdsRoof>true</holdsRoof>
<designationCategory>Structure</designationCategory>
<staticSunShadowHeight>1.0</staticSunShadowHeight>
<blockLight>false</blockLight>
<CostList>
<SteelBar>1</SteelBar>
<Glass>5</Glass>
</CostList>
<stuffCategories>
<li>Metallic</li>
<li>Woody</li>
<li>Stony</li>
</stuffCategories>
<costStuffCount>6</costStuffCount>
<building>
<ignoreNeedsPower>false</ignoreNeedsPower>
</building>
    <Comps>
<li>
<compClass>CompPowerTrader</compClass>
<transmitsPower>true</transmitsPower>
<basePowerConsumption>50</basePowerConsumption>
<shortCircuitInRain>false</shortCircuitInRain>
<soundPowerOn>PowerOnSmall</soundPowerOn>
<soundPowerOff>PowerOffSmall</soundPowerOff>
</li>
<li>
<compClass>CompGlower</compClass>
<glowRadius>12</glowRadius>
<glowColor>(217,217,208,0)</glowColor>
</li>
      <li Class="CommunityCoreLibrary.CompProperties_ColoredLight">
        <compClass>CommunityCoreLibrary.CompColoredLight</compClass>
      </li>
      <li Class="CommunityCoreLibrary.CompProperties_LowIdleDraw">
        <compClass>CommunityCoreLibrary.CompPowerLowIdleDraw</compClass>
        <idlePowerFactor>0.1</idlePowerFactor>
        <operationalMode>WhenNear</operationalMode>
      </li>
</Comps>
<damageMultipliers>
<li>
<damageDef>Bomb</damageDef>
<multiplier>3</multiplier>
</li>
</damageMultipliers>
<researchPrerequisite>LightedWalls</researchPrerequisite>
</ThingDef>


Unfortunately, building one of these then results in the debug log popping up with a red error (and the counter keeps increasing very quickly). See the attached PowerError.png for the callstack. (Couldn't figure out if there is any way to copy the debug log as text, or if it's being saved somewhere as text automatically).

Looking at your source, it appears that compPower is null in CompPowerLowIdleDraw.isItIdle, but the ThingDef does have a CompPowerTrader, and Log.Message( "Community Core Library :: CompPowerLowIdleDraw :: '" + parent.def.defName + "' needs compPowerTrader!" ); didn't get logged, so I'm not sure how that could happen.

As I was already looking through the source, I checked out what "WhenNear" actually means, and unfortunately I found that your and my definition of near in this context is very different.

If I read your code right, then "near" in this case (no interaction point) means the cell occupied by the wall, and the 8 cells around it.

So to make this actually work, beyond fixing whatever problem is causing the null pointer exception (be it a mistake in my xml definition or your code), will require the addition of a "within glow radius" operational mode. When building the scan positions for that, it should start at the object, then move up to "glowRadius from CompGlower" steps (only in 4 ways, not 8), stopping at any cell that has blockLight true. It would be nice if sleeping pawns could be ignored when scanning.

I'm not sure what the performance implications will be of having a lot of objections with relatively large scan ranges around. One possible optimization would be to remember the pawn that has been found in range, and on further ticks, only null that reference and start a new scan if that pawn is no longer in range. But that still won't prevent the probably relatively high cost of scanning if nothing is in range.


On to a different problem, when I loaded a savegame where that motion-activated wall was already build, I got a single NullReferenceException right after load pointing at something going wrong in CompColoredLight. I've attached the callstack as ColorError.png








[attachment deleted due to age]
Title: Re: [A11b] Community Core Library (v0.11.3)
Post by: 1000101 on July 29, 2015, 04:44:28 PM
Quote from: ypBwivc2aji6
Hi,

I've been playing around with this, and given that the LowIdleDraw code already automatically turns glow on/off, I figured I start with something easy and make a motion activated light.
LowIdleDraw isn't really intended to be used with ColoredLights, part of the reason is that some of the optimization strategies used by LowIdleDraw such as grabbing the needed ThingComps (power, glower) once would be defeated by changing the comp out from under it.  The code could be changed to get the comp via a property, but I'd rather avoid a bunch of getter properties if I can as a call is a lot more expensive then a memory reference and in some cases, it could actually end up being a long call chain.  Thus, it's done once and the result is cached.

Quote from: ypBwivc2aji6Community Core Library has been added to the Mods folder and is being loaded right after Core.

As I'm currently running the Ultimate Overhaul Modpack...

Unfortunately, building one of these then results in the debug log popping up with a red error (and the counter keeps increasing very quickly). See the attached PowerError.png for the callstack. (Couldn't figure out if there is any way to copy the debug log as text, or if it's being saved somewhere as text automatically).
(You can find your log in /RimWorld/RimWorldNNNWin_Data/output_log.txt)

Quote from: ypBwivc2aji6Looking at your source, it appears that compPower is null in CompPowerLowIdleDraw.isItIdle, but the ThingDef does have a CompPowerTrader, and Log.Message( "Community Core Library :: CompPowerLowIdleDraw :: '" + parent.def.defName + "' needs compPowerTrader!" ); didn't get logged, so I'm not sure how that could happen.
That is a strange thing unless you are changing out your power trader too.  I could see errors like that happening if the glower was changed, but the power trader should be static in this sense so the reference to it should be valid.

Quote from: ypBwivc2aji6As I was already looking through the source, I checked out what "WhenNear" actually means, and unfortunately I found that your and my definition of near in this context is very different.

If I read your code right, then "near" in this case (no interaction point) means the cell occupied by the wall, and the 8 cells around it.
"WhenNear" is intended for things in close proximity such as doors and the NPD.  So near is the entire area of the building and all adjacent cells and it discards cells which a pawn can't enter.  I choose this for a balance between speed and functionality.  For a larger radius I think it would just start lagging and there is Haplo (https://ludeon.com/forums/index.php?action=profile;u=161)'s PowerSwitch (https://ludeon.com/forums/index.php?topic=2890) mod which can be used for that purpose.

Quote from: ypBwivc2aji6So to make this actually work, beyond fixing whatever problem is causing the null pointer exception (be it a mistake in my xml definition or your code), will require the addition of a "within glow radius" operational mode. When building the scan positions for that, it should start at the object, then move up to "glowRadius from CompGlower" steps (only in 4 ways, not 8), stopping at any cell that has blockLight true. It would be nice if sleeping pawns could be ignored when scanning.

I'm not sure what the performance implications will be of having a lot of objections with relatively large scan ranges around. One possible optimization would be to remember the pawn that has been found in range, and on further ticks, only null that reference and start a new scan if that pawn is no longer in range. But that still won't prevent the probably relatively high cost of scanning if nothing is in range.
Performance is certainly an issue and that is why I specifically opted to not to have a radial scan.  In your example, even a small base with only 50 walls doing radial scans every ~30 ticks would really start to lag.  I decided instead to leave anything that wanted such a power toggle scheme to using the more centralized approach of the power switch mod.

Quote from: ypBwivc2aji6On to a different problem, when I loaded a savegame where that motion-activated wall was already build...
Loading a know-bad save will cause that.  Since you already knew that there was a problem with what you were attempting, I'm not sure why you would think any save would be valid.  :P
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: jacob814 on August 03, 2015, 03:16:03 PM
I am not getting the log msg saying CCL is loaded. It does show that in my modsconfig that ccl is loaded second and I assume that ccl is working because my machines are not useing power unless being in use as well as colored lights work. I did get CCL to work with my mod because I have gotten my ceiling lights only placable under a roof and my wall light only placable on a wall.

I tried what you said with putting Ancient tech mod into the mods folder and running it which i did. The problem is that is did show the ancient cryosleep casket without anything researched.

I am not getting error logs either so I am lost. It seems like CCL is running because of the colored lights. I did triple check to see if CCL was properly installed and I dont see why it isnt.

Here is my code: https://github.com/jacob814/Glass_N_Lights/releases/tag/0.5

Thankyou for you help.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: 1000101 on August 03, 2015, 03:41:30 PM
Could you send me your output_log.txt file as well? (RimWorldNNNWin_Data/output_log.txt)

The xml all looks good and it works for me.

Question, do you have god mode enabled?  If so, then everything will show up of course.  Also, AdvancedResearch isn't processed immediately, it's done every 250 ticks (one rare tick) so at a rate of 60 ticks/sec, a rare tick happens every ~4.17 seconds.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: jacob814 on August 03, 2015, 08:42:21 PM
I would understand if I was on god mod or not. Question does the colored celing lights show up for you or not without research? They shouldnt without colored lights/glass researched.

Output log in attachment

[attachment deleted due to age]
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: 1000101 on August 03, 2015, 11:19:25 PM
When I started [a new colony] I only had the "outdoor ground lamp" available.  After researching "glassworks research" I could make the "ceiling lamp", after researching "colored lights", I got the all the "ceiling lamp (color)" lights as expected.

So, for me everything worked as you intended it to.

As to the log, not sure why the message is missing.  Shortly after loading/starting a game (should be first tick), you should see the following message:

"Community Core Library :: Advanced Research :: Initialized"

If you don't get that message, you should get some sort of error message using a similar format ("Community Core Library :: Advanced Research :: error specifics").

Failing all that, I am at a bit of a loss to explain it.  I mean, something should have been logged and not just a silent fail.

On a side note, you are not ticking your restricted placement comp.  It needs a normal/rare ticker or removing the restriction (roof/wall/etc) won't be caught.  In your case you can get away with using a rare tick since nothing needs ticking otherwise.

Edit:

Have you tried a new world + new colony?  At the moment, CCL does not inject the MapComponent into existing saves.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: jacob814 on August 04, 2015, 08:49:17 AM
Hm.... I didnt think of that, even though I should of... It works

I know I am not ticking my restricted placement comp and the reason for this is because I just havent figure out how to. I dont think I could find an example in the example code. I may be wrong. If it is in the example code could you point me to it, im not having any luck finding it.

Thanks for the previous help. I dont know why I didnt try a new world...
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: 1000101 on August 04, 2015, 01:49:08 PM
There are placeworker restriction (https://github.com/RimWorldCCLTeam/CommunityCoreLibrary/blob/master/_Mod/Modders%20Resource/PlaceWorkers/PlaceWorker_Restrictions/Defs/ThingDefs/Buildings_PlaceWorker_Restrictions.xml) examples, the ones that need it all use <tickerType>Rare</tickerType>.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: Evul on August 13, 2015, 10:48:01 AM
Love it!
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: NephilimNexus on August 13, 2015, 05:34:05 PM
Tynan, hire these guys.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: Adamiks on August 14, 2015, 12:44:09 PM
Oh! Now i can be lazy as fuck and don't learn anything about C#! Like i always do! ;D
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: The13thRonin on August 20, 2015, 09:11:07 AM
Has the research locking for planting been done yet?
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: 1000101 on August 20, 2015, 09:49:32 PM
A while ago (before I posted it was done in your other thread).

Just waiting until the end of August to hear about A12 status before we release v0.11.5 or v0.12.0.  From all signs it looks like it will be v0.12.0.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: jacob814 on August 22, 2015, 09:34:26 AM
I cant wait for 12 for this. The only downside for using this system is we have to wait for this mod to update  before we can update ours.
Title: Re: [A11b] Community Core Library (v0.11.4)
Post by: 1000101 on August 22, 2015, 10:00:14 PM
Soon, we're doing final tests.

v0.12.0 is now released!
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: Latta on August 24, 2015, 12:37:10 PM
DefInjected translation is not working on HelpDef(s) and HelpCategoryDef(s). It's strange, I once translated custom defs and it worked just fine.
But in this case, the game just won't recognize HelpDef and HelpCategoryDef as valid, known def forms. Of course it works in game. :-X

By the way, do you prefer GitHub issues, or forum replies?
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: 1000101 on August 24, 2015, 05:30:46 PM
For library bugs I prefer github issues for tracking.
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: rsdworker on August 27, 2015, 08:41:15 AM
hello - where i do put user CCL in? - there was no instructions found on page or in zip so i am sure this goes in mod folder
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: 1000101 on August 27, 2015, 03:37:16 PM
You extract both directories into your mods folder.

So when you're done it would look like this:

/Mods/Community Core Library
/Mods/Community Core Library - Vanilla Tweaks
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: jacob814 on August 27, 2015, 07:50:32 PM
@rsdworker

make sure you download the right one and unzip it and put it in the mods folder. Unless a mod says otherwise, put the mod in the mods folder.

Hope this helps
Title: Re: [A12] Community Core Library (v0.12.0)
Post by: 1000101 on August 28, 2015, 07:09:58 PM
Sorry for the couple subtle (mod break) bugs in CCL related to injection (map components and designators).

These bugs are fixed and some new help menu features are done, a release should be by the end of the weekend.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: 1000101 on August 30, 2015, 04:17:45 PM
It's still sunday somewhere on Earth, so I made my deadline.

Updated and fixed.  New features?  Help AutoGen and ThingComp injection!  Read more about it on the github release page.  Fixes?  MapComponent and Designator injection.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: rsof69 on August 30, 2015, 09:28:51 PM
HELP

[attachment deleted due to age]
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: 1000101 on August 31, 2015, 12:42:08 AM
That looks like the result of a bad install.

Specifically, that tag (<buildingDefs>) used to be in the Alpha11 version but was refactored into thingDefs which means you have xml from a different alpha release.

Always delete the old mod and install the new copy, never just copy-pasta over top.  This is true for all mods.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: rsof69 on August 31, 2015, 12:48:39 AM
Quote from: 1000101 on August 31, 2015, 12:42:08 AM
That looks like the result of a bad install.

Specifically, that tag (<buildingDefs>) used to be in the Alpha11 version but was refactored into thingDefs which means you have xml from a different alpha release.

Always delete the old mod and install the new copy, never just copy-pasta over top.  This is true for all mods.

I always delete mod then replace it, the one with buildings def is clutter but the ccl what is that about ?
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: 1000101 on August 31, 2015, 01:24:01 AM
I've found the issue, Clutter has copied files from the CCL mod into it's own.  This is fine if it's simple xml overrides, but it's just copied things willy-nilly and the big-no-no, the DLL.  This is the cause of the error (I hadn't thought anyone would be silly enough to do this).
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: rsof69 on August 31, 2015, 02:33:11 AM
So thats why  :D and thanks for making modding more awsome with ccl
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: Demonlord091 on August 31, 2015, 09:05:09 PM
First time I install and activate the mod and I get an error.

Any ideas as to the cause?

[attachment deleted due to age]
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: Latta on August 31, 2015, 09:07:04 PM
You sure you loaded CCL right after the Core?
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: 1000101 on August 31, 2015, 11:13:01 PM
The complete lack of CCLs initialization strings is a dead give away that CCL isn't even loaded.

If it's loaded and working you should see a log which looks like this:

Community Core Library v0.12.1.0
Community Core Library :: Advanced Research :: Initialized
Community Core Library :: Help System :: Initialized
Community Core Library :: Initialized


If any one of those is missing, CCL failed to load properly at some step.  Check your loaded mods and make sure you have "Core [1]" and "Community Core Library [2]".  Everything else should be after those two.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: mbos14 on September 02, 2015, 04:31:47 PM
For some reason i now keep getting this error log wich just keeps repeating the same error. after saving and loading one of my colonys. i have tried older saves and saved them as test and the same things happens there. i get the feeling it has something to do with CCL. because it goes hambone right after it tries loading stuff for it.(if it does not have anything to do with your mod i appologize).

[attachment deleted due to age]
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: Latta on September 02, 2015, 07:46:29 PM
Sorry to say this, but I think that comes from mine.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: mbos14 on September 03, 2015, 08:09:44 AM
Quote from: Latta on September 02, 2015, 07:46:29 PM
Sorry to say this, but I think that comes from mine.
you want me to also post it on your mod post ?
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: Latta on September 03, 2015, 08:33:47 AM
Quote from: mbos14 on September 03, 2015, 08:09:44 AM
Quote from: Latta on September 02, 2015, 07:46:29 PM
Sorry to say this, but I think that comes from mine.
you want me to also post it on your mod post ?

No, it will be addressed in the next version.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: highlander345 on September 05, 2015, 07:52:52 PM
Hi, I have one of the same issues as rsof69, is this an incompatibility with Clutter at this point? or is there something else causing this error only

[attachment deleted due to age]
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: 1000101 on September 05, 2015, 10:53:31 PM
What CCL mods do you have, I know of one mod which has that issue but it has been updated to correct that.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: akiceabear on September 05, 2015, 11:22:25 PM
While it may be a bit of a slog, it would be nice to eventually have a list of CCL dependent mods in the first post - just to give people an idea of what's available and what's possible.
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: highlander345 on September 06, 2015, 03:17:43 PM
Currently I'm running with; Clutter, M&Co Enhanced Defense, Glitter Tech, Rimsenal, LT mods (infusion, redistheat, rimeffect), Misc + Mai and T's Mods, not all use CCL but that is my mod list, it was all working fine until I updated CCL, RedistHeat, MD2 Fortifications and added Clutter
Title: Re: [A12c] Community Core Library (v0.12.1)
Post by: highlander345 on September 06, 2015, 03:42:41 PM
I think I found the issue, EDB Mod Order Wasn't activating it directly after the core, so i cleaned installed and activated it before EDB Mod order and it seems to have worked, Not sure if just the clean install stopped the issue, or if that is directly responsible

EDIT: Mechanical Defense 2 Base causes the error to reoccur, I didn't know that it required CCL
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: 1000101 on September 12, 2015, 03:14:46 PM
Alpha 12d Update + Bug fixes!

See the commit log (https://github.com/RimWorldCCLTeam/CommunityCoreLibrary/pull/24) for full details.

Download link in OP.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: Tekuromoto on September 12, 2015, 04:57:19 PM
I have a small request: can you please remove the requirement of needing to research medical beds before you can plant xerigium? It seems a little off that you need to have a sterile surgical environment before you can produce herbal medicine that's "selectively bred for centuries by settlers. It is sometimes also called 'healer's hand' by tribespeople".  ???
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: 1000101 on September 12, 2015, 05:04:26 PM
I was on the fence about that.

You can edit the xml to remove that entry.  Completely delete lines 24-42 of:
/Mods/Community Core Library - Vanilla Tweaks/Defs/AdvancedResearchDefs/AdvancedResearch_Plants.xml

If you remove the whole file, it will also remove the Brewing requirement to grow hops.

If enough people want it gone (like, one more person ;) ), I'll remove that completely for the next release.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: Kulverstukass on September 12, 2015, 05:10:34 PM
Yep, i would like to see that part about "med. bed research" and xe-something-something growing, it makes sense, gotta be better start for colony.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: Falcon24 on September 13, 2015, 10:11:12 AM
Quote from: 1000101 on September 12, 2015, 05:04:26 PM
I was on the fence about that.

You can edit the xml to remove that entry.  Completely delete lines 24-42 of:
/Mods/Community Core Library - Vanilla Tweaks/Defs/AdvancedResearchDefs/AdvancedResearch_Plants.xml

If you remove the whole file, it will also remove the Brewing requirement to grow hops.

If enough people want it gone (like, one more person ;) ), I'll remove that completely for the next release.

I have the options to grow both of these plants from the beginning. Am I doing something wrong? I have CCL directly after Core, and CCL - Vanilla Tweaks right after that. I can see the requirements in the .xml file, but they don't appear to be making any effect. Thanks!
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: 1000101 on September 13, 2015, 02:49:51 PM
Quote from: Falcon24I have the options to grow both of these plants from the beginning. Am I doing something wrong? I have CCL directly after Core, and CCL - Vanilla Tweaks right after that. I can see the requirements in the .xml file, but they don't appear to be making any effect. Thanks!

I would need to know more like your mods config and output log.

Also, have to tried a new world + colony to make sure everything works correctly?
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: Falcon24 on September 13, 2015, 04:05:42 PM
Quote from: 1000101 on September 13, 2015, 02:49:51 PM

I would need to know more like your mods config and output log.

Also, have to tried a new world + colony to make sure everything works correctly?

I've attached the ModsConfig.xml and output_log.txt.
I have created new worlds and colonies, and everything appears to work correctly. Nothing seems out of place. I do notice that other parts of the vanilla tweaks work, such as the power draw reduction. I appreciate your help, although if the researches are the only things not working as fully intended, it won't bother me much.  ;)

[attachment deleted due to age]
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: 1000101 on September 14, 2015, 08:37:23 AM
I don't know specifically that any of those other mods affect the growing of hops or xerigium, but if another mod loaded with CCL which as automagically controls things of the same nature, you could see anomalies.

Also, output_log.txt
116: Community Core Library v0.12.1.0

According to that log, you're running the previous version.  Can you see if you encounter the same problem with 0.12.2?


Edit:

Looking through your mod list again, I see some mods you are using which haven't been updated for A12 yet.  There is no way of knowing what sort of interaction is happening there.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: enslavedeagle on September 15, 2015, 01:51:23 PM
Hey,

I got your mod along with many others and there's a bug in Vanilla Tweaks module.
When I placed a cooking stove in a new world and a new colony, it disappeared right after a colonist finished building it. The problem is gone now that I disabled the Vanilla Tweaks mod.

Keep up doing great job with your mods :)

I'm running CCL v0.12.2 on RimWorld v0.12.914.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: Kulverstukass on September 15, 2015, 01:59:38 PM
Quote from: enslavedeagle on September 15, 2015, 01:51:23 PM
Hey,

When I placed a cooking stove in a new world and a new colony, it disappeared right after a colonist finished building it.

I'm running CCL v0.12.2 on RimWorld v0.12.914.
Gotta check, if .dll of CCL tweaks (if there should be one) still in "Assemblies" folder in mod's folder.
Had same problem with another mod some time ago, it was the answer.
Title: Re: [A12d] Community Core Library (v0.12.2)
Post by: 1000101 on September 15, 2015, 02:49:13 PM
The Vanilla Tweaks contains no dll, it is strictly xml.  CCL is doing nothing to anything (geothermal) and the VTs change the cookstove to add CompPowerLowIdleDraw.  If the cookstove is doing other strange things, it's some other strange mod.
Title: Re: [A12d] Community Core Library (v0.12.3)
Post by: 1000101 on September 22, 2015, 07:36:41 PM
Alpha 12 Update 2b

Many minor bug fixes, removes Xerigium research requirements.  Additional functions for C#.

See the commit log (https://github.com/RimWorldCCLTeam/CommunityCoreLibrary/pull/32) for full details.

Download link in OP.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: jerome736 on September 22, 2015, 10:19:45 PM
Thanks for the Xerigium change!
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: cucumpear on September 23, 2015, 12:57:43 AM
Quote from: jerome736 on September 22, 2015, 10:19:45 PM
Thanks for the Xerigium change!

Seconded, because I ended up using the exploit a lot where I could select Xerigium at the very beginning of the game if I paused quickly enough.  :P
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on September 23, 2015, 03:22:50 AM
Quote from: lautnitha on September 23, 2015, 12:57:43 AM
Quote from: jerome736 on September 22, 2015, 10:19:45 PM
Thanks for the Xerigium change!

Seconded, because I ended up using the exploit a lot where I could select Xerigium at the very beginning of the game if I paused quickly enough.  :P

Cheater!  ;P

As I said before, I was on the fence about it.  I had it in for testing but forgot to remove it for an actual release.  :)
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: njb013 on October 02, 2015, 09:49:17 AM
I get a series of errors every time I load (but not create) a colony. I'm pretty sure it's a problem with this mod and not the others. The amount of RimWorld.faction errors varies from colony to colony; this has only one, but I have another with around ten.

http://puu.sh/kvQgp/edea1eb066.jpg
Disabling the vanilla changes mod did not fix the problem.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on October 02, 2015, 01:25:58 PM
CCL does nothing with factions.  If you could attach your full log, that would be helpful.

You can find your log (on Windows) in the "_Data" directory.  It will be called "output_log.txt"
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: njb013 on October 02, 2015, 02:17:15 PM
I redownloaded the mods I was using and everything works again. Not sure what caused the issue, but sorry for thinking it was your mod.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: Loki88 on October 10, 2015, 11:59:54 AM
Okay I was hoping to be able to figure this out w/o having to bug you but it seems I'm still a Derp :( Is there a functionality within CCL to allow a building to create a zone around itself such as what trade beacons and sunlamps do?

I just want to know if I can define within my sunlamp's .xml file to let it create growing zone with a radius of "x" so to speak.

I will keep poking around in the modders' resources but my brain doesn't want to co-operate right now.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on October 10, 2015, 03:00:02 PM
There is no "create zone x in radius y" method in CCL.  The radius which the sunlamp uses for creating the grow zone is it's specialDisplayRadius.  This is the radius which is "fully lit".

As to adding a general purpose comp to CCL which one could specify the zone and radius as well as the icon and text for the gizmo is possible too I suppose...
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: Loki88 on October 10, 2015, 04:59:13 PM
Quote from: 1000101 on October 10, 2015, 03:00:02 PM
There is no "create zone x in radius y" method in CCL.  The radius which the sunlamp uses for creating the grow zone is it's specialDisplayRadius.  This is the radius which is "fully lit".

As to adding a general purpose comp to CCL which one could specify the zone and radius as well as the icon and text for the gizmo is possible too I suppose...

Don't worry about it if it's a pain in the butt. I was more or less just asking if I was missing something.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on October 10, 2015, 07:08:19 PM
Not so much a pain in the but as just not previously considered.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: Loki88 on October 10, 2015, 07:39:58 PM
It's not something that can be used by a ton of things minus grow lights and trade beacons. Perhaps dumping stock piles for crematoriums, but that's a whole other ball of wax since they don't have a display radius. Hmmmm. Either way CCL has gotta be the most useful thing to happen to RimWorld modding. I appreciate all your hard work making this beast!
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: TLHeart on October 10, 2015, 07:45:46 PM
just a confusion from the front page, proper refrigeration only works if vanilla tweaks is used, but it is listed as if it is part of the core program... without vanilla tweaks, the refrigeration code does not work in game.

edit: now I am confused, started a new colony and built a food storage tray without vanilla tweaks, and it says refrigerated. 
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: 1000101 on October 10, 2015, 10:07:10 PM
CCL only provides the means to properly refrigerate, it requires a mod to actually add a refrigerator however, in the modders examples there is a refrigerated meal shelf.  This example for modders is for reference although it could be used for normal gameplay.  Vanilla tweaks contains no refrigerated storage as there are no vanilla food storage buildings to apply the changes (ThingComp) to.  The Clutter (https://ludeon.com/forums/index.php?topic=2541) mod by mrofa adds a refrigerator and atm, is the only mod I know of which uses it.

Sorry for any confusion on this, it was not intentional.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: TLHeart on October 11, 2015, 12:01:37 AM
Quote from: 1000101 on October 10, 2015, 10:07:10 PM
CCL only provides the means to properly refrigerate, it requires a mod to actually add a refrigerator however, in the modders examples there is a refrigerated meal shelf.  This example for modders is for reference although it could be used for normal gameplay.  Vanilla tweaks contains no refrigerated storage as there are no vanilla food storage buildings to apply the changes (ThingComp) to.  The Clutter (https://ludeon.com/forums/index.php?topic=2541) mod by mrofa adds a refrigerator and atm, is the only mod I know of which uses it.

Sorry for any confusion on this, it was not intentional.

I know it is not intentional, I took the beantek storage tray, modified it with the example you provide, and it works. I also add the example code to skullwags extended storage food tray, and it worked there for me also, yet others can not get it to work, so I was just trying to understand what is going on.
Title: Re: [A12d] Community Core Library (v0.12.3b)
Post by: cuproPanda on October 11, 2015, 12:41:58 AM
Quote from: TLHeart on October 11, 2015, 12:01:37 AM
Quote from: 1000101 on October 10, 2015, 10:07:10 PM
CCL only provides the means to properly refrigerate, it requires a mod to actually add a refrigerator however, in the modders examples there is a refrigerated meal shelf.  This example for modders is for reference although it could be used for normal gameplay.  Vanilla tweaks contains no refrigerated storage as there are no vanilla food storage buildings to apply the changes (ThingComp) to.  The Clutter (https://ludeon.com/forums/index.php?topic=2541) mod by mrofa adds a refrigerator and atm, is the only mod I know of which uses it.

Sorry for any confusion on this, it was not intentional.

I know it is not intentional, I took the beantek storage tray, modified it with the example you provide, and it works. I also add the example code to skullwags extended storage food tray, and it worked there for me also, yet others can not get it to work, so I was just trying to understand what is going on.

The problem for me seems to have been stemming from CompProperties_LowIdleDraw. With that comp, none of the options worked, but once I removed that code block altogether, all options now keep the food refrigerated, and give the correct report string listed in CompInspectStringExtra(). This works just fine for me, since I can just have the racks draw a constant power instead of cycling. I didn't test using any other LowIdleDraw options.

EDIT: Ignore me. Everything is working fine now after removing, adding, and reorganizing my mods. CCL and CCL-VT were always right after Core, but there was something somewhere that was causing a conflict. PEBCAK.