Jump to content

[Creature Mod] Help Using Tall Bird Brain


ubeaest

Recommended Posts

I was following the Creature Mod tutorials made by Cheerio to create a new creature in the game, but when I was using the Tall Bird Brain as a reference for its brain I ran into an issue. These two functions conflict:

 

From the Brain:

function Brain:OnInitializationComplete()    self.inst.components.knownlocations:RememberLocation("home", Point(player.Transform:GetWorldPosition()))end

From the Modmain:

function SpawnCreature(player)--Get player's current position.local x, y, z = player.Transform:GetWorldPosition()--Spawn creature at the world origin.local creature = GLOBAL.SpawnPrefab("anthropophagi")--Move creature to the player's position.creature.Transform:SetPosition( x, y, z ) endAddSimPostInit(SpawnCreature)

 

What I think is going on:

  1. The first one asigns a "home" location to the creature after game initialization.
  2. The second one spawns the creature at the world origin after player initialization. 

Does anyone know a solution for asigning it a "home" location on the origin after the player initializes?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...