• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Actor Visibility

Status
Not open for further replies.
Level 11
Joined
Aug 1, 2009
Messages
963
Hey, just wondering, is there any way to make an actor visible ONLY to one player?

I want to create range indicators for abilities (using custom UI) via triggers, only it seems that they are always visible to everyone. This means that everyone else can tell when you are preparing an ability, kinda lame.

Thanks.
 
Level 2
Joined
Dec 1, 2007
Messages
11
I know there is, given the comments for the Actor natives. (http://paste.sc2mapster.com/1979/)

Actor comments said:
// - Trigger code is synchronous and actors are asynchronous. This means we can't have any
// routines that return any results, since anything from the actor system is suspect.
// This includes even the existence of actors themselves; an actor might only be created on
// machines with good graphics cards, for instance.

(Not sure exactly how to do it, though.)
 
Level 11
Joined
Aug 1, 2009
Messages
963
Well yeah, but for the map I was making it used a custom UI rather than the base UI. So, you would press a key on the keyboard to activate an ability, upon which it would display a range-indicator around you to show where you can use that ability.

But I kinda scrapped that project anyways so meh.
 
Level 2
Joined
Dec 1, 2007
Messages
11
That quote means nothing at all.

He wants an invisible actor, actor for one person. Do you see return anywhere in there?

Hmm... after looking a bit further, there appears to be no currently available function to do so. Also, within that comment it says "Trigger code is synchronous", and it further elaborates that they make every effort to have the actor functions be synchronous:

Code:
In other words, the client always appears to get a valid object,
but the user has no way of actually knowing whether it was valid,
except to look at the screen.

So right now, there isn't any method of getting a local player. It's also possible there never will be.

On the other hand, there is probably a method of making a unit/actor invisible/transparent (not just cloaked) and then share visibility with certain players, or something to that effect.
 
Status
Not open for further replies.
Top