Primitive 0x0075 - Age

This primitive physically ages a Sim (humanoid or pet) to a different life stage.

Note, it does not perform the myriad other tasks (fulfilling wants/fears, adding memories, affecting aspiration, enrolling in school, etc, etc, etc) associated with changing age group! For full details on what aging entails refer to the following BHAVs - 0x1009 "Age Transition" and 0x1046 "CT - College Age" both in the "Controller - Age" object, and 0x1002 "Sub - Give Youth" in the "Controller - Wishes - Youth" object.


Use

There is no SimPe wizard for this instruction, so the following table details the meaning of each of the operands.

OperandDescriptionOperand Values
0 Age to transistion to (see also bit 1 of Op1) 0x00: Adult
0x01: Child
0x02: Toddler
0x03: Teen
0x04: Elder
0x0E: Young Adult
1 - bit 1 Controls where Age is taken from Off: Use value in Op0
On: Use value from Temp 0
2 thru 15 Unused

See Also


SimPe Code

// Decompiled with JetBrains decompiler
// Type: pjse.BhavNameWizards.WizPrim0x0075
// Assembly: pjse.coder.plugin, Version=4.0.3349.37576, Culture=neutral, PublicKeyToken=null

using SimPe.PackedFiles.Wrapper;
using System;

namespace pjse.BhavNameWizards
{
  public class WizPrim0x0075 : BhavWizPrim
  {
    public WizPrim0x0075(Instruction i)
      : base(i)
    {
    }

    protected override string Operands(bool lng)
    {
      byte[] numArray = new byte[16];
      ((byte[]) this.instruction.Operands).CopyTo((Array) numArray, 0);
      ((byte[]) this.instruction.Reserved1).CopyTo((Array) numArray, 8);
      string str = "";
      return ((int) numArray[1] & 1) == 0 ? str + BhavWiz.readStr(GS.BhavStr.AgePrimAges, (ushort) numArray[0]) : str + this.dataOwner((byte) 8, (ushort) 0);
    }
  }
}