lesson4.txt

txt file icon
Fact Value
Original File lesson4.txt
Game
  • Creatures 1
Creator
  • LummoxJR
Wiki Link Search "lesson4" on creatures.wiki
Tags
File Size: 4 KB

Description(Generated)

Text File Composite

::----- lesson4.txt -----::
COB Tutorial
Lesson 4: Fertility infusion 

It has come to my attention that I skipped over a very important type of COB: an infusion. Basically, an infusion object isn't an object at all; it's just a script that tells the game to do something, in this case to pump chemicals into the currently selected creature.
The important thing to know about infusions and similar scripts is that they require no class number. You're not actually creating an object, but just giving a few commands to the game. So don't worry about family, genus, and class; they're irrelevant in this case.

Since the process is pretty easy, I'm going to make a more complicated kind of infusion: A fertility infusion. This should increase fertility of a male Norn or a non-pregnant female by boosting both sex drive and testosterone or estrogen.

Step 1: The installation script
Before you do anything, start CobCom and click on the word "" in the Scripts list. Go to the Scripts menu and select Delete Script. I forgot to mention this previously, but it's important.
I'm going to skip ahead of planning, which is usually the first step. I know what I want this infusion to do, so I'm just going to go ahead and do it.

As ever, the first step (well, the second in this case) is to click the list box marked "Installation Scripts" ("Imports" in CobCom 1.02 or earlier) and enter in a script there.

In the edit box, type in the following:

inst
targ norn
doif gnus ne 1
stop
endi
doif spcs eq 1
stim writ norn 0 255 0 0 29 255 64 255 0 0 0 0
else
doif baby ne 0
stop
endi
doif chem 66 gt 0
stop
endi
stim writ norn 0 255 0 0 29 255 63 255 0 0 0 0
endi
endm

Now, let's look through the lines particular to this script.

targ norn
Sets the currently selected creature as the target. This is probably redundant, but it makes good sense to put it in anyway.

doif gnus ne 1
 <...truncated>