# WEAPON:CalcViewModelView

- **Ortam:** İstemci
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/WEAPON:CalcViewModelView
- **Çeviri tarihi:** 2025-09-08

```lua
Vector, Angle WEAPON:CalcViewModelView( Entity ViewModel, Vector OldEyePos, Angle OldEyeAng, Vector EyePos, Angle EyeAng )
```

## Açıklama

Viewmodel'in pozisyonunu ve açısını geçersiz kılmaya (override) olanak tanır. Bu hook yalnızca [GM:CalcViewModelView](https://gmod.tr/wiki/GM:CalcViewModelView)'ı geçersiz kılmadıysanız çalışır.

## Argümanlar

1. [Entity](https://gmod.tr/wiki/Entity) **ViewModel**: Viewmodel entity'si
2. [Vector](https://gmod.tr/wiki/Vector) **OldEyePos**: Orijinal pozisyon (viewmodel sallanması ve yalpalamasından önce)
3. [Angle](https://gmod.tr/wiki/Angle) **OldEyeAng**: Orijinal açı (viewmodel sallanması ve yalpalamasından önce)
4. [Vector](https://gmod.tr/wiki/Vector) **EyePos**: Mevcut pozisyon
5. [Angle](https://gmod.tr/wiki/Angle) **EyeAng**: Mevcut açı

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

1. [Vector](https://gmod.tr/wiki/Vector): Yeni pozisyon
2. [Angle](https://gmod.tr/wiki/Angle): Yeni açı

### Örnek

SWEP'inizin viewmodel dokusunu (skin) değiştirmenin bir yolu. Değeri 0'dan 1'e değiştirir.

Örneğin [Crowbar](https://developer.valvesoftware.com/wiki/Crowbar) kullanarak .smd dosyasını .mdl'ye derlerken modeliniz için temel yolu ([$cdmaterials](https://developer.valvesoftware.com/wiki/$cdmaterials)) tanımlamayı unutmayın; aksi takdirde hiçbir doku uygulanmaz. (oyun nereye bakacağını bilemez) [QC Commands](https://developer.valvesoftware.com/wiki/Category:QC_Commands)

Ve birden çok skin için [$texturegroup](https://developer.valvesoftware.com/wiki/$texturegroup) kullanmayı unutmayın.

```lua
function SWEP:CalcViewModelView(ViewModel, OldEyePos, OldEyeAng, EyePos, EyeAng)
    -- SWEP'in ikinci skinini ayarlar; 1. 0'dan başlar
    ViewModel:SetSkin(1)
end
```

**Çıktı:** ![](https://gmod.tr/api/uploads/wiki/af7168fef36bba29aca0.jpg) ![](https://gmod.tr/api/uploads/wiki/86d3faaf3d24fcd0e340.jpg)

- [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/WEAPON:CalcViewModelView
