22 lines
464 B
Markdown
22 lines
464 B
Markdown
# Darklord.js — applyPotionSafe() (satır 3004)
|
||
|
||
[← Darklord.js](index.md) · [← Master](../../wiki.md)
|
||
|
||
```javascript
|
||
function applyPotionSafe(player, id, ticks, amplifier, particles)
|
||
{
|
||
try
|
||
{
|
||
var potion = mappet.getPotion(id);
|
||
if (potion != null)
|
||
{
|
||
player.applyPotion(potion, ticks, amplifier, particles);
|
||
return true;
|
||
}
|
||
}
|
||
catch (e) {}
|
||
|
||
return false;
|
||
}
|
||
```
|