Files

24 lines
730 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# KlonlanmaLal.js — createActorClone() (satır 193)
[← KlonlanmaLal.js](index.md) · [← Master](../../wiki.md)
```javascript
function createActorClone(c, owner, x, y, z, index) {
try {
var tag = mappet.createCompound("{NoAI:1b,Silent:1b,Invulnerable:1b,PersistenceRequired:1b}");
var clone = c.getWorld().spawnEntity("blockbuster:actor", x, y, z, tag);
if (!clone) {
return { entity: null, error: "blockbuster:actor spawnEntity null" };
}
setupCommonClone(clone, owner, index);
syncMorph(owner, clone);
return { entity: clone, error: "" };
} catch (e) {
return { entity: null, error: String(e) };
}
}
```