Files

37 lines
1.2 KiB
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.
# TelekinesiLal.js — startHold() (satır 193)
[← TelekinesiLal.js](index.md) · [← Master](../../wiki.md)
```javascript
function startHold(c, owner, target) {
var old = loadState();
if (old.active) {
var oldTarget = findEntityByUuid(c, old.target);
if (oldTarget) unlockHard(oldTarget);
}
var w = c.getWorld();
var pos = target.getPosition();
var s = defaultState();
s.active = true;
s.mode = "hold";
s.owner = owner.getName();
s.target = uuidOf(target);
s.tick = 0;
s.broken = old.broken || {};
s.restores = old.restores || [];
lockHard(target, pos.x, pos.y, pos.z);
noMotion(target);
fx(w, "portal", pos.x, pos.y + 1.0, pos.z, 42, 0.35, 0.65, 0.35, 0.08);
fx(w, "spellWitch", pos.x, pos.y + 1.0, pos.z, 30, 0.28, 0.45, 0.28, 0.035);
w.playSound(SOUND_START, pos.x, pos.y + 1.0, pos.z, 1.1, 0.75);
w.playSound(SOUND_HOLD, pos.x, pos.y + 1.0, pos.z, 0.8, 1.35);
saveState(s);
owner.send("\u00a7d[Kisil] \u00a7f" + target.getName() + " \u00a77telekineziye alindi. Click veya \u00a7fDefol \u00a77ile firlat.");
c.scheduleScript("kisilLoop", LOOP_INTERVAL);
}
```