Alpha 9 Modder Stuff

Started by ItchyFlea, January 16, 2015, 08:45:42 PM

Previous topic - Next topic

skullywag

Is there something up with Graphic random, lots of people seem to be having issues with it, anyone have a working mod with it in.
Skullywag modded to death.
I'd never met an iterator I liked....until Zhentar saved me.
Why Unity5, WHY do you forsake me?

blaze7736

For my plants the vanilla textures use the graphic random but my textures use the single i don't now why but random works for the potato plant textures

Shinzy

#62
Alloo!
The trader's carry true/false was made away with, how would I now mark stuff
as 'not sold' by one?
I noticed all them trade tag things but atm I'm really unsure how to work them =P
Edit: oh never mind! it's literally in the first post ;D /blind
Editwo: Oh thanks a bunch for this thread by the way!

editrhee:
Oh now that I'm here! the apparel
      <Insulation_Heat>7</Insulation_Heat> things, how do they really differ from
      <ComfyTemperatureMax>7</ComfyTemperatureMax> bits?
cause those both still work and all I could tell there was only different description between the two
okay it's just the insulation gets affected by the quality level and the other one always stays the same


Gaesatae

Quote from: Shinzy on February 21, 2015, 07:40:55 AM
editrhee:
Oh now that I'm here! the apparel
      <Insulation_Heat>7</Insulation_Heat> things, how do they really differ from
      <ComfyTemperatureMax>7</ComfyTemperatureMax> bits?
cause those both still work and all I could tell there was only different description between the two

I can't look at it now, but if I'm not mistaken the <Insulation_Heat> is the value factored by the <Insulation_Heat> statfactor from the stuff to get the final ComfyTemperatureMax. I didn't know that you can still set the ComfyTemperatureMax directly in apparel.

Shinzy

Quote from: Gaesatae on February 21, 2015, 11:13:46 AM
Quote from: Shinzy on February 21, 2015, 07:40:55 AM
editrhee:
Oh now that I'm here! the apparel
      <Insulation_Heat>7</Insulation_Heat> things, how do they really differ from
      <ComfyTemperatureMax>7</ComfyTemperatureMax> bits?
cause those both still work and all I could tell there was only different description between the two

I can't look at it now, but if I'm not mistaken the <Insulation_Heat> is the value factored by the <Insulation_Heat> statfactor from the stuff to get the final ComfyTemperatureMax. I didn't know that you can still set the ComfyTemperatureMax directly in apparel.
oh thanks! I did some old fashioned testing myself =P the insulation bit is a stat unlike the other one which is an offset
so it gets affected by the quality (I just didn't notice at first cause all my items were 'normal' quality cause of how the game starts so :-[ shoulda have done moar testing before coming here ;D)

skullywag

Have we answered the "amount of skill gain a recipe adds" yet, I see we can a skill to up but can we no longer specify the amount?
Skullywag modded to death.
I'd never met an iterator I liked....until Zhentar saved me.
Why Unity5, WHY do you forsake me?

Shinzy

#66
Quote from: skullywag on February 21, 2015, 11:52:56 AM
Have we answered the "amount of skill gain a recipe adds" yet, I see we can a skill to up but can we no longer specify the amount?

wasn't it tied to like the length of crafting process?
as in you don't get a lump of exp from finished product but rather gain skill as you make the thing
so you wouldn't need separate skill gain

Edit: like in, if it takes long time to make clearly it gives more experience, but if you zip zap zup right through like an old doer
there's not much more to learn
it makes a whole lot of sense to me =P
I have some real life experience on carpentry, with some wooden lists I had to smoothen the ends of
the person who showed me how to do it did it in under a second while my go at it at same speed resulted in like a barbeque stick

this would also result in grandmaster crafters not recieving so much skill from the small thing cause they make them a whole lot faster

I think this is what has been done with the skill gain
Theory, no facts to back claimstm Shinzy(c) all rights reserved.

Gaesatae

Quote from: skullywag on February 21, 2015, 11:52:56 AM
Have we answered the "amount of skill gain a recipe adds" yet, I see we can a skill to up but can we no longer specify the amount?

I found this in the toils...
p.skills.GetSkill(job.RecipeDef.workSkill).Learn(0.11f * job.RecipeDef.workSkillLearnFactor);

So you can add to the recipe Defs:
<workSkillLearnFactor>50</workSkillLearnFactor> for example.
I just tested it in the simple meal recipe, it works.

Shinzy

Quote from: Gaesatae on February 21, 2015, 02:53:36 PM
Quote from: skullywag on February 21, 2015, 11:52:56 AM
Have we answered the "amount of skill gain a recipe adds" yet, I see we can a skill to up but can we no longer specify the amount?

I found this in the toils...
p.skills.GetSkill(job.RecipeDef.workSkill).Learn(0.11f * job.RecipeDef.workSkillLearnFactor);

So you can add to the recipe Defs:
<workSkillLearnFactor>50</workSkillLearnFactor> for example.
I just tested it in the simple meal recipe, it works.

would that give 50 points of exp on the skill or what does it do? (Since you tried it already so I don't have to go try myself! Yes I'm very very lazy ;D sorry!)

Gaesatae

It's just 0.11 * 50; 0.11 is the hardcoded value that get factored by the workSkillLearnFactor value (1 by default) each time the pawn do some work on a bill. 50 is a very big number, just cooking one meal was +1k xp.

rakkaus

It's there a difference how "RangedWeapon_Cooldown" works vs "MeleeWeapon_Cooldown" at the moment?

StorymasterQ

Quote from: Orion on February 20, 2015, 04:31:47 PM
Okay, I found the issue: in alpha 9, mechanoids don't have toes or ringfingers anymore. I needed to remove all references to them.
Although I'm not a modder, I find this interesting. Mechanoids not having toes, I can understand, but specifically no ring fingers? Just the ring fingers? What about the other ones? Are you saying mechanoids can't get married? This is discrimination! :D
I like how this game can result in quotes that would be quite unnerving when said in public, out of context. - Myself

The dubious quotes list is now public. See it here

mrofa

Why gizmo .... what was bad with the old one...
Btw any one know how to operate on textures in code now?
All i do is clutter all around.

Frazzles

Does anyone know where the location of the code for armour degradation over time and armour taking Health damage from absorbing damage is?

Haplo

Quote from: mrofa on February 24, 2015, 05:13:55 AM
Why gizmo .... what was bad with the old one...
Btw any one know how to operate on textures in code now?
Gizmos are just a function name change:

        public override IEnumerable<Gizmo> GetGizmos()
        {
            // Add base.GetGizmos()
            List<Gizmo> baseList = base.GetGizmos().ToList();
            for (int i = 0; i < baseList.Count; i++)
                yield return baseList[i];


            int groupBaseKey = 31367670;

            // Key-Binding B - Call owner To rest
            Command_Action opt1;
            opt1 = new Command_Action();
            opt1.disabled = owner == null;
            opt1.disabledReason = txtNoOwner.Translate();
            opt1.defaultDesc = txtSendOwnerToSleep.Translate();
            opt1.icon = UI_ForceSleepButton;
            opt1.hotKey = KeyBindingDefOf.Misc1;
            opt1.activateSound = SoundDef.Named("Click");
            opt1.action = Button_CallOwnerToRest;
            opt1.groupKey = groupBaseKey + 1;
            yield return opt1;


And Graphics code: this should work:

Graphic graphic = GraphicDatabase.Get<Graphic_Single>(graphicPath, ShaderDatabase.Cutout, IntVec2.one, color, color2);