This class was added by a mod with mod-id zensummoning. So you need to have this mod installed if you want to use this feature.

Diese Klasse importieren

Link to diese-klasse-importieren

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

ZenScript
Copy
import mods.zensummoning.MobInfo;

Name: create

Creates a new MobInfo with default values. <br /> See other methods for adding more customization.

Returns: new MobInfo
Return Type: MobInfo

ZenScript
Copy
// MobInfo.create() as MobInfo

MobInfo.create();

Name: setCount

Sets the quantity of the mob to be spawned.

Return Type: MobInfo

ZenScript
Copy
// MobInfo.setCount(count as int) as MobInfo

myMobInfo.setCount(12);
ParameterTypeBeschreibung
Parameter
count
Type
int
Beschreibung
quantity

Name: setData

Sets the NBT data of the mobs to be spawned.

Return Type: MobInfo

ZenScript
Copy
// MobInfo.setData(data as IData) as MobInfo

myMobInfo.setData({
 "Health":200,
 "Attributes":[
 {"Name":"generic.maxHealth", "Base":200},
 {"Name":"generic.movementSpeed", "Base":0.3},
 {"Name":"generic.attackDamage", "Base":6}
 ],
 "CustomName":"A Lost Soul",
 "PersistenceRequired":1,
 "CustomNameVisible":1
 });
ParameterTypeBeschreibung
Parameter
data
Type
IData
Beschreibung
NBT

Name: setMob

Sets the mob to be spawned.

Return Type: MobInfo

ZenScript
Copy
// MobInfo.setMob(mob as string) as MobInfo

myMobInfo.setMob("minecraft:zombie_villager");
ParameterTypeBeschreibung
Parameter
mob
Type
string
Beschreibung
resource location

Name: setOffset

Sets the offset from the altar where the mobs will be spawned.

Return Type: MobInfo

ZenScript
Copy
// MobInfo.setOffset(x as int, y as int, z as int) as MobInfo

myMobInfo.setOffset(1, 3, 1);
ParameterTypeBeschreibung
Parameter
x
Type
int
Beschreibung
x
Parameter
y
Type
int
Beschreibung
y
Parameter
z
Type
int
Beschreibung
z

Name: setSpread

Sets the random spread for spawning the mob. Values shouldn't be negative.

Return Type: MobInfo

ZenScript
Copy
// MobInfo.setSpread(x as int, y as int, z as int) as MobInfo

myMobInfo.setSpread(3, 3, 3);
ParameterTypeBeschreibung
Parameter
x
Type
int
Beschreibung
x spread
Parameter
y
Type
int
Beschreibung
y spread
Parameter
z
Type
int
Beschreibung
z spread