Author Topic: Feed your animals  (Read 1786 times)

0 Members and 1 Guest are viewing this topic.

Offline casey

  • Administrator
  • Marine Biologist
  • *
  • Posts: 1842
Feed your animals
« on: January 19, 2005, 07:41:30 PM »
Posted by: many moles Dec. 13 2004, 03:51 AM
Hi,

I've been playing with the ZT2 code, and now I'vde found a way to feed your animals yourself. At the moment it's only working with the black leopard, 'cause it's code quite easierr to understand than the whole game. If you unzip (description is here anywhere) the LeopardAndDummy.z2f you downloaded from M$, you find a couple of files. The file I've moddified is found in entities/units/animals/AI. Open the LeopardBlack.xml with a texteditor, go to line 46 which must read . There you find two actions: One for cleanng the black leopard and one for healing him. All I've done is to "copy&paste" one line and changed it to the following


 


 



I've tested it quickly in freeform mode. Build an exhibit an place the black lion in there. Make sure there are no food dishes in the exhibit. Water is just fine since you can't feed him water at the moment. Let the game run a while, then look for the fairly high hunger indicator.. Go in guest mode to your leopard and it will show "press spacebar to brush your leopard" or soemthing like that. After doing this once, be sure hit spacebar only one time, you will see another yellow circle around your leopard with no message occuring. Yeah go right ahead and press spacebar again. You just feed your leopard, quick look at the stats shows hunger indicator is empty.

Feel free to add a line to feed your leopard water.

Now I'm searching through the orginal game files to find an correspondending line of code there... Stay tuned

many moles

[edit] The "effect" parameter isn't used so there is no need to refer to something non existing.  

Posted by: many moles Dec. 13 2004, 04:41 AM
To add a message to the yellow circle you must unpck your lang.z2f file from your ZT2 directory. There you find a file named staff_actions.xml. in that file all staff text notes defined including the superstaff notes if you are in guest mode. After the last superstaff line I've added one like this for the new command


 

Press SPACEBAR to feed %s.
 



My last lines will look like this


 

      Drücken Sie die LEERTASTE, um den Kompost zu verkaufen.
      Drücken Sie die LEERTASTE, um %s zu füttern.

 



Of course your's will have english text..

many moles  

Posted by: sharkman222 Dec. 13 2004, 09:10 AM
I will try and see if I can make the comp show a message for it  

Posted by: many moles Dec. 13 2004, 09:28 AM
The message will appear if you edit the staff_actions.xml file like said above. I'm working on getting an animation to show up when feeding your animal. Like chewing or something. Unfortunaly i must stick with existing ones...

many moles  

Posted by: flamethrower Dec. 13 2004, 03:39 PM
Nice find. Added to list of useful topics.

I'm curious why they didn't insert it as a feature. Is there anything wrong with it?

Maybe they ran short of time, left it half finished, and plan to overwrite the files with a finished one in the expansion pack.  Better not expand too far on this.

Offline casey

  • Administrator
  • Marine Biologist
  • *
  • Posts: 1842
Feed your animals
« Reply #1 on: January 19, 2005, 07:41:30 PM »
Posted by: many moles Dec. 13 2004, 03:51 AM
Hi,

I've been playing with the ZT2 code, and now I'vde found a way to feed your animals yourself. At the moment it's only working with the black leopard, 'cause it's code quite easierr to understand than the whole game. If you unzip (description is here anywhere) the LeopardAndDummy.z2f you downloaded from M$, you find a couple of files. The file I've moddified is found in entities/units/animals/AI. Open the LeopardBlack.xml with a texteditor, go to line 46 which must read . There you find two actions: One for cleanng the black leopard and one for healing him. All I've done is to "copy&paste" one line and changed it to the following


 


 



I've tested it quickly in freeform mode. Build an exhibit an place the black lion in there. Make sure there are no food dishes in the exhibit. Water is just fine since you can't feed him water at the moment. Let the game run a while, then look for the fairly high hunger indicator.. Go in guest mode to your leopard and it will show "press spacebar to brush your leopard" or soemthing like that. After doing this once, be sure hit spacebar only one time, you will see another yellow circle around your leopard with no message occuring. Yeah go right ahead and press spacebar again. You just feed your leopard, quick look at the stats shows hunger indicator is empty.

Feel free to add a line to feed your leopard water.

Now I'm searching through the orginal game files to find an correspondending line of code there... Stay tuned

many moles

[edit] The "effect" parameter isn't used so there is no need to refer to something non existing.  

Posted by: many moles Dec. 13 2004, 04:41 AM
To add a message to the yellow circle you must unpck your lang.z2f file from your ZT2 directory. There you find a file named staff_actions.xml. in that file all staff text notes defined including the superstaff notes if you are in guest mode. After the last superstaff line I've added one like this for the new command


 

Press SPACEBAR to feed %s.
 



My last lines will look like this


 

      Drücken Sie die LEERTASTE, um den Kompost zu verkaufen.
      Drücken Sie die LEERTASTE, um %s zu füttern.

 



Of course your's will have english text..

many moles  

Posted by: sharkman222 Dec. 13 2004, 09:10 AM
I will try and see if I can make the comp show a message for it  

Posted by: many moles Dec. 13 2004, 09:28 AM
The message will appear if you edit the staff_actions.xml file like said above. I'm working on getting an animation to show up when feeding your animal. Like chewing or something. Unfortunaly i must stick with existing ones...

many moles  

Posted by: flamethrower Dec. 13 2004, 03:39 PM
Nice find. Added to list of useful topics.

I'm curious why they didn't insert it as a feature. Is there anything wrong with it?

Maybe they ran short of time, left it half finished, and plan to overwrite the files with a finished one in the expansion pack.  Better not expand too far on this.

Offline cheetahgirl

  • Pooper Scooper
  • *
  • Posts: 16
Feed your animals
« Reply #2 on: May 08, 2005, 12:23:33 PM »
I don't know if i am posting this in the right forum or not so please move it if it is in the wrong place. :huh   I am having problems finding the Black Leopard files, in fact i can't find the musk ox files either.   :sad I have the patch, I downloaded it with the other download files.  I tried to use the copy and paste thing for a different animal but it would not let me edit anything.  Has anyone else had similar promblems like mine.  If anyone knows how to fix this or has any other helpful information it would be greatly appreciated.  Please and Thank You.

Offline karlhall39

  • Zookeeper
  • *
  • Posts: 245
    • http://
Feed your animals
« Reply #3 on: May 08, 2005, 02:01:13 PM »
where r the files kept?

Offline cheetahgirl

  • Pooper Scooper
  • *
  • Posts: 16
Feed your animals
« Reply #4 on: May 10, 2005, 12:14:44 PM »
if you are asking me i do not know I downloaded everything from the game using the downloads option on the main menu, so I have no idea where the game put them.  I have checked in just about every file and folder I can find.

Offline karlhall39

  • Zookeeper
  • *
  • Posts: 245
    • http://
Feed your animals
« Reply #5 on: May 11, 2005, 10:56:31 AM »
i was asking casey any way looking forward to find out how to do them

Offline karlhall39

  • Zookeeper
  • *
  • Posts: 245
    • http://
Feed your animals
« Reply #6 on: May 16, 2005, 09:27:08 AM »
i have found the files put i carnt do anything it wont let my copy and paste help plz
EDIT: scap that how do you do it for water?
EDIT2: i can do the musk ox