Originally Posted by ProgMaster
if target~=nil then
Is that possible with TargetChanged event or party:GetMember():GetTarget() to retrieve the target object of player in your party (not yourself)?
Well, for starters, you should be using the AddCallback method to assign event handlers. Additionally, since the TargetChanged event will pass the caller as its first parameter, you can use the same event handler for everybody.
Create a table of target names with the player's names as keys. Then create a function that sets the sender's target value and attach that event to all of the players.
if tmpTarget==nil then
if party~=nil then
for index=1,party:GetMemberCount()-1 do
note, you will have to remove entries from the targetName table when
members are removed and attach handlers to new members as they are added, etc. but that's the basic idea.
for more information on AddCallback