# weapons.IsBasedOn

- **Ortam:** İstemci, Sunucu
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/weapons.IsBasedOn
- **Çeviri tarihi:** 2025-09-08

```lua
boolean weapons.IsBasedOn( string name, string base )
```

## Açıklama

`name` ile belirtilen sınıfın `base` ile belirtilen sınıfa dayalı olup olmadığını kontrol eder.

## Argümanlar

1. [string](https://gmod.tr/wiki/string) **name**: Kontrol edilecek varlığın sınıf adı
2. [string](https://gmod.tr/wiki/string) **base**: Kontrol edilecek temel sınıf adı

## Döndürülen Değer

1. [boolean](https://gmod.tr/wiki/boolean): Eğer sınıf adı belirtilen temele dayanıyorsa `true`, aksi takdirde `false` döndürür.

### Örnek

`gmod_tool`'un `weapon_base`'e ve `weapon_base`'in kendisine dayalı olup olmadığını kontrol eden bir örnek.

```lua
print(weapons.IsBasedOn("gmod_tool", "weapon_base"), weapons.IsBasedOn("weapon_base", "weapon_base"))
```

**Çıktı:** true
false

- [GMod Wiki ana sayfası](https://gmod.tr/wiki)

---

[Tüm sunucular](https://gmod.tr/) · [GmodTR Launcher](https://gmod.tr/launcher) · [Rehber](https://gmod.tr/rehber) · [GMod Wiki](https://gmod.tr/wiki) · [GmodTR nedir?](https://gmod.tr/hakkinda) · [Sunucu ekle](https://gmod.tr/sunucu-ekle) · [Discord](https://discord.gg/gmodtr)

Kaynak: https://gmod.tr/wiki/weapons.IsBasedOn
