![]() |
Help
NPC Code: I need it to be so it can show the players account not my account, you know when you put your mouse over them it shows there account. Someone please help me :\ |
Wow...
You work on a server? |
Quote:
and... wat is this supposed to be? |
//#CLIENTSIDE
if (created){ timeout = .05; } if (timeout){ if (mousex in |playercraphere,playercraphere| && mousey in|playercraphere,playercraphere|){ setplayerprop #c,#a; // #c is the players chat and #a is account } timeout = .05; } // You have to have timeout = .05; inside the timeout itself for it to loop. Ohh, and if this is to test another player and not yourself you're best using testplayer(x,y); |
Quote:
That will still work but it is bad scripting. Anyway, you need to iterate through 'playerscount' and check the mousex/y in players[index].x/y. Then display the account using #a(index). |
Umm, I was fixing his script not giving him a whole new one. It's not bad advice becaue I was fixing what he already had and testplayer(x,y) returns the index of the player so you don't have to do what you said.
Don't be such a prick aswell. Wee, good advice. |
Quote:
Also last time I checked, testplayer index does not work on clientside anymore. It returns 0 for yourself, or it returns -1. Anyone care to debate? Nonetheless, iterating through all the players in a level using a for loop, then checking coordinates using players[index].xy, then using #a(index) to display the account name will work. |
Quote:
|
Quote:
|
| All times are GMT +2. The time now is 05:00 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.