Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DEBATE] : 2 ways for implementing more artificial organs #11

Closed
kaptain-kavern opened this issue Jul 21, 2016 · 35 comments
Closed

[DEBATE] : 2 ways for implementing more artificial organs #11

kaptain-kavern opened this issue Jul 21, 2016 · 35 comments

Comments

@kaptain-kavern
Copy link
Owner

kaptain-kavern commented Jul 21, 2016

Preliminary informations :

For the features we have in now, i just applied the mechanics existing for vanilla implants and artificial limbs to animal. No knew implants have been added in order to achieve that.


Now for adding new artificial organs/implants we have to use :

  • New recipes in RecipesDefs folder - it's where we specify to the game :
    1. What is needed in order to perform the surgery (the <ingredients> and <fixedIngredientFilter> tag)
    2. On which BodyPart the Recipe can be applied (the <appliedOnFixedBodyParts> tag)
    3. What effect the new artificial BodyPart will induce (the <addsHediff> tag)
  • New item in ThingDefs_Item - where we define the item (in our case : implants or artificial organs) characteristics such as :
    1. Which trader will bring this particular item and its price (the <tradeTags> tag and <MarketValue> tag)
    2. In which category the game will class the item (the <thingCategories> tag)
    3. Determine which pawn (colonist, traders, raiders or tribes, etc...) can spawn with it (<techHediffsTags>) (i'm not sure if it will/can affect the animal the trader brings for example and maybe it's not that important ...)
  • Add all the recipes to animal races in ThingDefs_Races (like i've done for those already in the mod) for the game to know if recipe is available or not for each
  • Add a way to actually get the items :
    • Either the possibility to craft them, which means : Benches (New ThingDefs_Bulding for the bench itself + RecipeDefs for crafting them + WorkGiverDefs for the bills at benches) and Research projects (new ResearchProjectDefs)
    • Or via traders. Existing (vanilla) ones (with the <tradeTags> tag) or by creating new traders (in TraderKindDefs)
  • Eventually add :
    • New induced needs and thought of the new artificial organs/implants (in ThoughtDefs)
    • New induced effect of the new artificial organs/implants (in HediffDefs)

So either we rewrite entirely new implants and such or we use EPOE (in which all of these are already define for human pawns) the same way i've done for adding vanilla artificials organs/implants

@inkyspoon
Copy link
Collaborator

So I just uploaded a few files adding animaljaw and animalspine. I had to add a new hediffdefs folder too, so that when adding parts via console and epoe the parts are named different (bc epoe has spine and jaw too) I don't know maybe its unecessary I did it anyway^^. also the jaw does not work for birds, my guess is bc birds have a beak, not a jaw? I don't know how to change it so maybe someone else could look into it?
I tried to add a thing called animal denture that is crafted like pegleg, with wood and not a bought item, but, sadly, I failed miserably lol. It just wouldn't show up. I added everything like pegleg with right names ofc just with ingredient woodlog instead of the item itself, it still wouldn't show up in surgeries. (added in surgeries.xml and racesdef but no showing up)

@inkyspoon
Copy link
Collaborator

Also, I didn't know how to commit all changed files at once, so i added all individually that's why there are so many lol maybe some help for next time? xD

@kaptain-kavern
Copy link
Owner Author

he nice. i see that you start to mess with the code. cool man and you even manage to correct yourself. That's it you're a modder.

Also today i managed to get EPOE to work with ADogSaid

Cassowary of doom again
Cassowary of doom again

@kaptain-kavern
Copy link
Owner Author

the problem now : not all implants/prosthese/surgeries from EPOE should be usable on animals. So it's Dev Mode bug testing for now (tell me if you want me to upload the file to test it for yourself)

@inkyspoon
Copy link
Collaborator

yeah I could test it see what I can do :) did you test the ears etc? Its working but I'm not sure I did everything right. DO we want to release the update to the public with the additions?

@inkyspoon
Copy link
Collaborator

also the ears and the birds..don't know how to fix em seems the game says that birds have no ears lol

@inkyspoon
Copy link
Collaborator

and I'm not a "man" btw 😜

@kaptain-kavern
Copy link
Owner Author

kaptain-kavern commented Jul 23, 2016

Ho i'm so sorry :p
I've pushed on new branche in order to not erase your changes (i will go look after in Dev branche) : https://github.com/kaptain-kavern/ADogSaid/tree/EPOE-Compatible (you have to load EPOE first in mod order)

as for the bird you're right ... no <ear> in Bodies_Animal_Bird.xml at all . lol i guess we have to mod that too (by adding the tags ourselves like in other Bodies_xxx.xml)

@inkyspoon
Copy link
Collaborator

done. birds have ears now. xD

@inkyspoon
Copy link
Collaborator

inkyspoon commented Jul 23, 2016

so as far as I understand from the epoe compatible files, is that you enabled the epoe stuff to be used on animals? But wouldn't that mean that we don't need all the extra animal parts? I thought we would make it compatible by adding animal parts ( just the few we need for animals) to the crafting benches so they can be crafted there? bc I'm not so sure on being able to use human bionics on animals, they're too expensive in my opinion to be used on animals. so what I think would make sense, is two versions of the mod:

  1. for people who don't use epoe (there are some..^^) they can get the animal parts from traders.
  2. people who use epoe can get animal parts from traders AND craft them on epoe benches, but way cheaper than human stuff

@kaptain-kavern
Copy link
Owner Author

No your right. This was more like a start.
We indeed need to make specific animals parts (and i agree with you about the cost argument), but i guess we can use EPOE's HediffDefs.

And that's exactly how i see things with the two versions but i haven't though about the "trader trick" that's clever and i like it


About Github and committing several files at once (you asked earlier), here is how i work :

I use the Github desktop app. That way i can work on my computer, fiddle in the xml files, test ingame etc. When i think i reach a step, i go in the app and commit my changes (leaving notes even when working alone - That's the golden rule! ). Then i go work on files again, etc ... At this point all the changes still are local (on my computer), it's only when you choose to sync on the app that the changes will be updated on the repo (in the branche you choose).

For files editing (on windows) i recommend either Sublime Text or Atom. Some also prefer Notepad++. (http://rimworldwiki.com/wiki/Modding_Tutorials/Recommended_software)

@inkyspoon
Copy link
Collaborator

yeah I'm already using notepad++ didn't know about the app though. Later I figured out that I could just drag all the folders into the upload and it would only show the changes^^ didn't know that at first so the first 6 commits or so I just uploaded every file separately xD

@inkyspoon
Copy link
Collaborator

back to the epoe stuff: I think all we need to add is maybe something like an animal brain stimulator and maybe heart+lungs. I don't think its neccessary to have more stuff for animals. afaik you don't need more than that to keep animals functioning. so all we would have to do then, is add all the animal parts to the workbench recipes

@kaptain-kavern
Copy link
Owner Author

You mean you don't think people will want to add advanced bionics in their pets?

@kaptain-kavern
Copy link
Owner Author

birds have ears now

Should be the name of the next release :p

@inkyspoon
Copy link
Collaborator

I think most people just want to not have to euthanize their useless blind immobile pets ^^ i would like to keep the mod as simple as possible maybe add a "pegleg" version for jaw but that's it. you know all the neccessary bits nothing fancy^^

@inkyspoon
Copy link
Collaborator

lol yeah haha xD

@kaptain-kavern
Copy link
Owner Author

I respect that. I guess we will add with 2 another versions :

  • With OP bionics for animals
  • Nothing fancy edition :p

'cause i think most of the guys out there (and i mean guy this time) will want cyberdogs and shit like that. I propose we start with the "nothing fancy" option and see peoples reactions ;)

@inkyspoon
Copy link
Collaborator

how about this:
we already have simple and advanced stuff for legs. prosthetic and bionic.
we add simple stuff to jaw
and the rest stays advanced because e.g. eyes that are gold etc are useless for animals (they don't have social and can't see with gold eye anyway) and spine, organs, ears and brain chip are internal stuff that can only be advanced in my opinion

@inkyspoon
Copy link
Collaborator

oh ok we could do that too lol xD

@inkyspoon
Copy link
Collaborator

inkyspoon commented Jul 23, 2016

we could also just ramp up the stats for bionic parts so that people who want cyberdogs are satisfied with the bionic parts and for people who dont care, they have the simple parts of the important things like legs and jaw all in one mod.

@kaptain-kavern
Copy link
Owner Author

Ok so for now we only take from EPOE :

  • Prosthetic Jaws
  • Artificial brain, lungs and lungs

What else ?

@kaptain-kavern
Copy link
Owner Author

kaptain-kavern commented Jul 23, 2016

+ once our core files will be in place (even for few recipe + item) it will be simple to just add more

@inkyspoon
Copy link
Collaborator

another problem I thought of, is (at least that was the case in a13) when you give the animals legs and jaw, the dps goes down. bc in bodydefs animals have teeth and claws and horns attached, which do damage, but on replacing those bodyparts with bionics those things dissapear (like hands on humans when you replace arm) and the damage drops.

@inkyspoon
Copy link
Collaborator

we don't actually nedd to take them from epoe we can just make our own? I don't think we need more than that, we already have ears and spine

@kaptain-kavern
Copy link
Owner Author

Look in Hediffs_Local_AddedParts.xml for part about PowerClaw and ScytherBlade. we can define damage in the Hediffdef itself. i guess we can manage that from there

@kaptain-kavern
Copy link
Owner Author

kaptain-kavern commented Jul 23, 2016

haaaaaaaa right . you're right.

For know we do like this by adding our own, and after i'll try an optionnal compatibility patch and drop with EPOE for now. (glad you're here for that kind of thing too :p , i tend to go in every direction and all :p )

In fact i wasn't thinking right and have forgotten that all of those were already ingame :p

@inkyspoon
Copy link
Collaborator

inkyspoon commented Jul 23, 2016

yes and after we have all of our own items, we can look into how to add them to the workbenches and that would be the epoe integrated version. no need to use epoe's parts on animal then^^

@kaptain-kavern
Copy link
Owner Author

I'm all OK with that. Great!

So for now forget my branche about EPOE, we stick to Dev where there is already your commit and work from that. ok with you ?

@inkyspoon
Copy link
Collaborator

inkyspoon commented Jul 23, 2016

yep ok. and about the damage all we woud have to do is add

<comps>
      <li>
        <compClass>HediffComp_VerbGiver</compClass>
        <verbs>
          <li>
            <verbClass>Verb_MeleeAttack</verbClass>
            <defaultCooldownTicks>70</defaultCooldownTicks>
            <meleeDamageBaseAmount>15</meleeDamageBaseAmount>
            <meleeDamageDef>Scratch</meleeDamageDef>
          </li>
        </verbs>
      </li>
    </comps>

to the bionic legs and we have at least some damage back
and <meleeDamageDef>Bite</meleeDamageDef> to the jaw I guess

@inkyspoon
Copy link
Collaborator

inkyspoon commented Jul 23, 2016

so I guess we wait with release until we have all the parts at least and with the damage? I can work later today on that. shouldn't take to long. but right now I need to sleep its 7 am ^^

@kaptain-kavern
Copy link
Owner Author

kaptain-kavern commented Jul 23, 2016

I think that's all yes.

I cannot test right know. I don't know if I already tell but I live in France and it's 7 in the morning here :-p

It's cool to work on that with you, I like what the future "Birds have ears" update start to look like ;-)

@inkyspoon
Copy link
Collaborator

ah well I'm from germany and at least we're in the same timezone lol

@kaptain-kavern
Copy link
Owner Author

Oh we are in the same TZ. OK we'll release with the basics stuff we talked about earlier. The " less fancy" option with ears, jaw, and vital organs maybe. First deliver by trader (that is releasable itself) and after add the possibility to craft them (even in a vanilla hi tech bench to keep it simple like you said) in the 1.2 "Frankenstasoar" (craft your own pet) update :-p

@inkyspoon
Copy link
Collaborator

lol ok^^ bien dormir!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants