I've been wanting to make a script where you can click players to see info about them and here's what I'm trying to do right now
what I want the code below to do is tell me in the chat the name and bl_id of a player when I click them but the problem is the targets info doesn't show up (the rest of the message does)
package id
{
function Player::activateStuff(%player)
{
%v = Parent::activateStuff(%player);
%client = %player.client;
%target = containerRayCast(%player.getEyePoint(),vectorAdd(vectorScale(vectorNormalize(%player.getEyeVector()),2),%player.getEyePoint()),$TypeMasks::PlayerObjectType,%player);
if(!isObject(%target) || %target == %player || %player.getObjectMount() == %target)
return %v;
messageclient(%client, '', "\c6Name: \c3" @ %target.name @ " \c6BL_ID: \c3" @ %target.getblid());
return %v;
}
};
activatePackage(id);
can someone help me out?