Class:apiName(Parameters) | Return | Description |
Creature:getAttr(objid: number,CreaturesAttr) | ErrorCode.OK, value: number | Get the creature's attribute setting |
Creature:setAttr(objid: number,CreaturesAttr, val: number) | ErrorCode.OK | Set the creature's attribute |
Creature:isAdult(objid: number) | ErrorCode.OK | Determine whether the creature is an adult |
Creature:setOxygenNeed(objid: number, v: boolean) | ErrorCode.OK | Set whether the creature relies on oxygen |
Creature:getTamedOwnerID(objid: number) | ErrorCode.OK, uin: number | Get the ID of the creature's domestication master (0 means untamed) |
Creature:setPanic(objid: number, v: boolean) | ErrorCode.OK | Set whether the creature is panicking |
Creature:setAIActive(objid: number, v: boolean) | ErrorCode.OK | Set whether the creature's AI is active |
Creature:getActorID(objid: number) | ErrorCode.OK, actorid: number | Get the biological actorID |
Creature:getActorName(objid: number) | ErrorCode.OK, name: string | Get the name of the creature |
Creature:addModAttrib(objid: number, MOD ATTR TYPE, value: number) | ErrorCode.OK | Increase module attributes |
Creature:getModAttrib(objid: number, MOD ATTR TYPE) | ErrorCode.OK, value: number | Get module attributes |
Creature:setTeam(objids: number, teamid: number) | ErrorCode.OK | Set the creature's team |
Creature:getTeam(objid: number) | ErrorCode.OK, teamid: number | Get the creature's team |
Creature:getMaxFood(objid: number) | ErrorCode.OK, value: number | Get the maximum hunger of the creature |
Creature:getFood(objid: number) | ErrorCode.OK, value: number | Get the hunger of the creature |
Creature:setFood(objid: number, val: number) | ErrorCode.OK | Set the hunger of the creature |
Creature:getHpRecover(objid: number) | ErrorCode.OK, value: number | Get HP recovery of the creature |
Creature:getMaxOxygen(objid: number) | ErrorCode.OK, value: number | Get the maximum oxygen value of the creature |
Creature:getWalkSpeed(objid: number) | ErrorCode.OK, value: number | Get the walking speed of the creature |
Creature:getSwimSpeed(objid: number) | ErrorCode.OK, value: number | Get the swimming speed of the creature (speed in water) |
Creature:getJumpPower(objid: number) | ErrorCode.OK, value: number | Get the jump force of the creature |
Creature:getMass(objid: number) | ErrorCode.OK, value: number | Get the weight of the creature |
Creature:getDodge(objid: number) | ErrorCode.OK, value: number | Get the dodge of the creature |
Creature:getPunchAttack(objid: number) | ErrorCode.OK, value: number | Get the melee attack of the creature |
Creature:getRangeAttack(objid: number) | ErrorCode.OK, value: number | Get the remote attack of the creature |
Creature:getPunchDefense(objid: number) | ErrorCode.OK, value: number | Get the short-range defense of the creature |
Creature:getRangeDefense(objid: number) | ErrorCode.OK, value: number | Get the long-range defense of the creature |
Creature:setMaxHp(objid: number, val: number) | ErrorCode.OK | Set the maximum health points of the creature |
Creature:setHP(objid: number, val: number) | ErrorCode.OK | Set the health points of the creature |
Creature:setHpRecover(objid: number, val: number) | ErrorCode.OK | Set the HP recovery rate of the creature |
Creature:setOxygen(objid: number, val: number) | ErrorCode.OK | Set the oxygen level of the creature |
Creature:setWalkSpeed(objid: number, val: number) | ErrorCode.OK | Set the walking speed of the creature |
Creature:setSwimSpeed(objid: number, val: number) | ErrorCode.OK | Set the swimming speed of the creature (speed in water) |
Creature:setJumpPower(objid: number, val: number) | ErrorCode.OK | Set the jump force of the creature |
Creature:setDodge(objid: number, val: number) | ErrorCode.OK | Set the dodge of the creature |
Creature:setPunchAttack(objid: number, val: number) | ErrorCode.OK | Set the melee attack of the creature |
Creature:setRangeAttack(objid: number, val: number) | ErrorCode.OK | Set the remote attack of the creature |
Creature:setPunchDefense(objid: number, val: number) | ErrorCode.OK | Set the short-range defense of the creature |
Creature:setRangeDefense(objid: number, val: number) | ErrorCode.OK | Set the long-range defense of the creature |
Creature:replaceActor(objid: number, actorid: number, hp: number) | ErrorCode.OK | Replace the creature with a new biological |
Creature:GetMonsterDefName(monsterid: number) | ErrorCode.OK, name: string | Get the name of the creature type |
Creature:GetMonsterDefDesc(monsterid: number) | ErrorCode.OK, desc: string | Get the description of the creature type |