SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 13/04/2011, 09:51 AM   #1
Lorenc_
High-roller
 
Lorenc_'s Avatar
 
Join Date: Jan 2010
Location: Australia
Posts: 4,120
Reputation: 919
Default Looping :/

Well yer i need a loop that could loop through completely all NPC's created, i'm using CNPC although not using the features that are against the SA-MP TOS. Just creating some NPC's around and preventing from so many timers.

I clearly forgot how to do this method :/
__________________

192.169.82.202:7777 - An awesome CnR server consisting of doozy features! Come, we have players!


Lorenc_ is offline  
Old 13/04/2011, 10:11 AM   #2
(SF)Noobanatior
Gangsta
 
Join Date: Dec 2006
Posts: 562
Reputation: 2
Default Re: Looping :/

pawn Code:
for(new i=0;i<MAX_PLAYERS;i++){
if(!IsPlayerConnected(i))continue;
if(IsPlayerNPC(i)){
//do stuff
}
}
? that what ya after?
(SF)Noobanatior is offline  
Old 13/04/2011, 10:16 AM   #3
Lorenc_
High-roller
 
Lorenc_'s Avatar
 
Join Date: Jan 2010
Location: Australia
Posts: 4,120
Reputation: 919
Default Re: Looping :/

yup maddawg thanks
__________________

192.169.82.202:7777 - An awesome CnR server consisting of doozy features! Come, we have players!


Lorenc_ is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Looping through hits Ihsan-Cingisiz Help Archive 9 19/03/2011 03:17 PM
Looping through all the players? mrcoolballs Help Archive 2 07/09/2010 06:45 AM
Looping Pvars Dark_Kostas Help Archive 4 06/04/2010 07:18 AM
Looping cu MOA Alxxie Română/Romanian 4 03/04/2010 06:56 PM
Looping OnPlayerRequestClass cmg4life Help Archive 2 02/02/2010 04:07 AM


All times are GMT. The time now is 09:39 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.