![]() |
Player Classes and Level NPCs
So i have a class that controls player functions and used the NPC Control to apply this class to all players that log in. I have also made -Message weapon and connected the same player functions to that weapon ( this is for if i call it in a level NPC on clientside). However when i use the player.funct(); on serverside, and say i need that funct() to trigger clientside to display a showtext or something, it gets to the serverside funct() but doesnt go through the trigger. Why would this be? Here is my player_functions class.
Note: The weapon works fine. PHP Code:
|
You can't trigger a class (since a class just extends something else) or a player object. You need to trigger one of the player's weapons clientside.
|
I am not understanding. Basically im trying to have a level NPC send a string to be displayed on clientside using showtext/showimg.
My setup: Class for player_functions, which is joined to the player via NPC control Level NPC- aka person in house attached to class script with join. In addition i have a weapon named -Messages which holds the player_functions by join command. |
Control-NPC:
PHP Code:
PHP Code:
PHP Code:
PHP Code:
|
Okay thank you so much, so this is one of the cases where you wouldn't use this.name for the name of the NPC in triggerclient. Plus i also had it laid out a bit screwy so i'm sure that's part of it as well. thanks again.
|
Quote:
|
| All times are GMT +2. The time now is 07:36 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.