Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Future Improvements (https://forums.graalonline.com/forums/forumdisplay.php?f=10)
-   -   npcscount/playerscount (https://forums.graalonline.com/forums/showthread.php?t=20777)

btedji 01-09-2002 10:17 PM

npcscount/playerscount
 
make playerscount ONLY count real players on the level and NOT showcharacter npcs

make separate counts for normal npcs and show character npcs

Tyhm 01-10-2002 02:22 AM

No. It was like that and everything broke.

realplayerscount as a new variable might be good, but you can generally achieve the same effect with a decent for-next loop on playerenters.

NPC Code:
if(playerenters){
this.realplayerscount=1;
for(this.i=1;this.i<playerscount;this.i++){
if(players[this.i].id>=0) this.realplayerscount++;
}
}



All times are GMT +2. The time now is 04:53 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.