# CreateParticleSystem

- **Ortam:** İstemci
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/Global.CreateParticleSystem
- **Çeviri tarihi:** 2025-11-03

```lua
CNewParticleEffect CreateParticleSystem( Entity ent, string effect, number partAtt, number entAtt = 0, Vector offset = Vector( 0, 0, 0 ) )
```

## Açıklama

Yeni bir parçacık sistemi oluşturur. Ayrıca bakınız: [Entity:CreateParticleEffect](https://gmod.tr/wiki/Entity:CreateParticleEffect), [ParticleEffectAttach](https://gmod.tr/wiki/Global.ParticleEffectAttach) ve [CreateParticleSystemNoEntity](https://gmod.tr/wiki/Global.CreateParticleSystemNoEntity).

> **NOT:** Parçacık efektinin kullanılabilmesi için öncelikle [PrecacheParticleSystem](https://gmod.tr/wiki/Global.PrecacheParticleSystem) ile önbelleğe alınması ve geldiği dosyanın [game.AddParticles](https://gmod.tr/wiki/game.AddParticles) ile eklenmesi gerekir!

## Argümanlar

1. [Entity](https://gmod.tr/wiki/Entity) **ent**: Kontrol noktasının bağlanacağı entity.
2. [string](https://gmod.tr/wiki/string) **effect**: Oluşturulacak efektin adı. Önceden [PrecacheParticleSystem](https://gmod.tr/wiki/Global.PrecacheParticleSystem) ile önbelleğe alınmış olmalıdır.
3. [number](https://gmod.tr/wiki/number) **partAtt**: [PATTACH enum](https://gmod.tr/wiki/Enums/PATTACH)'una bakın.
4. [number](https://gmod.tr/wiki/number) **entAtt** = 0: Parçacık sisteminin bağlanacağı entity üzerindeki eklenti ID'si
5. [Vector](https://gmod.tr/wiki/Vector) **offset** = Vector( 0, 0, 0 ): Bu CP'yi (kontrol noktasını) bağladığımız entity'nin [Entity:GetPos](https://gmod.tr/wiki/Entity:GetPos)'undan olan uzaklık.

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

1. [CNewParticleEffect](https://gmod.tr/wiki/CNewParticleEffect): Oluşturulan parçacık sistemi.

### Örnek

Oyuncunun ayaklarının dibinde büyük bir patlama efekti oluşturur ve başladıktan 0.1 saniye sonra onu siler.

```lua
PrecacheParticleSystem( "explosion_huge_g" )

concommand.Add( "test_particle", function( ply, cmd, arg )

	local part = CreateParticleSystem( ply, "explosion_huge_g", PATTACH_POINT_FOLLOW )
	timer.Simple( 0.1, function() part:StopEmission( false, true, false ) end )

end )
```

- [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/Global.CreateParticleSystem
