• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Question about move unit instantly action

Status
Not open for further replies.
Level 6
Joined
Feb 19, 2010
Messages
182
Anybody know why the action move unit instantly always issues a stop order as it runs?
I found out why spells and stuff can't be casted because of perodically interrupted orders from that gui action
I always thought it paused the unit but what it seems to do is issue a stop order and then moves it...

Maybe detection of orders issued correctly causes the action to perform at its best to start? I doubt that, but I would prefer to hear your thoughts guys and girls.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
WarManta said:
Anybody know why the action move unit instantly always issues a stop order as it runs?

It's just one of those things.

WarManta said:
I found out why spells and stuff can't be casted because of perodically interrupted orders from that gui action

You could use custom script. There are methods of setting a unit's coordinates without that small pause action. The lines are:
JASS:
call SetUnitX( udg_YourUnit, udg_YourXVar )
call SetUnitY( udg_YourUnit, udg_YourYVar )

The variables associated here are GUI created, named YourUnit, YourYVar, and YourXVar. The udg_ prefix is added to GUI variables. You are free to rename them as you please.

Here's how it would look in GUI:

  • Untitled Trigger 001
    • Events
    • Conditions
    • Actions
      • Set YourUnit = (Triggering unit)
      • Set YourXVar = (Target X of current camera view)
      • Set YourYVar = (Target Y of current camera view)
      • Custom script: call SetUnitX(udg_YourUnit, udg_YourXVar)
      • Custom script: call SetUnitY(udg_YourUnit, udg_YourYVar)
WarManta said:
Maybe detection of orders issued correctly causes the action to perform at its best to start? I doubt that, but I would prefer to hear your thoughts guys and girls.

It really isn't much of an issue for me. I use vJass and I'm long past using the SetUnitPosition native. As I said above, you're free to use the custom script lines to perform the action without the stop (so it won't interrupt orders). Just take a look at how I did my Knock Back Lite library. You can test the map (don't open it) and see that units being knocked back still retain their orders to their full extent.
 
Actually, it were the same people.
The reason for BJs is the following:
They have a GUI script with parameters (values) and thought it would be easier to keep the same parameter order, so they made the BJs. (And also they thought well, you will never want to use this without blargh, so we will just always use it).

(For example creating texttags in GUI calls tons of methods)

Actually, I like it that blizzard did it that way. There is no other way to magically know which parameters and values are what in the jass functions.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
WarManta said:
What you said still looks like in jass, thanks though...

Berbanog said:
  • Untitled Trigger 001
  • Events
  • Conditions
  • Actions
    • Set YourUnit = (Triggering unit)
    • Set YourXVar = (Target X of current camera view)
    • Set YourYVar = (Target Y of current camera view)
    • Custom script: call SetUnitX(udg_YourUnit, udg_YourXVar)
    • Custom script: call SetUnitY(udg_YourUnit, udg_YourYVar)

Last time I checked this was GUI. Also, what? You can't use the slightest bit of JASS? What will you melt or something?

Jesus I come to this thread and give a lengthy description of how to avoid the evil of the pause with SetUnitPosition only to be dismissed by some half-wit newbie who doesn't care to read anything I say because there are two lines of JASS included in the same post as the GUI work-around. Just in case it's unclear, I'm talking specifically about WarManta. Don't expect me to review any of your threads (though it looks like you're die-hard GUI anyways) because if you don't even want to read what I have to say after I take the time to explain it to you then *POOF*.

I really need to stop wasting my fucking time with these idiots on the forums.
 
Level 8
Joined
Nov 9, 2008
Messages
502
Lol. Chill Winston.

@Warmanta
Unfortunately the only way around that GUI fail is through using Jass, much like many other GUI fails.
Just think of the custom script as another GUI function.
Besides, there are a lot more things you can do when you have learnt a bit of Jass, I highly recommend listening to Burbanog and learning a bit about Jass.
 
Level 6
Joined
Feb 19, 2010
Messages
182
"Last time I checked this was GUI. Also, what? You can't use the slightest bit of JASS? What will you melt or something?

Jesus I come to this thread and give a lengthy description of how to avoid the evil of the pause with SetUnitPosition only to be dismissed by some half-wit newbie who doesn't care to read anything I say because there are two lines of JASS included in the same post as the GUI work-around. Just in case it's unclear, I'm talking specifically about WarManta. Don't expect me to review any of your threads (though it looks like you're die-hard GUI anyways) because if you don't even want to read what I have to say after I take the time to explain it to you then *POOF*.

I really need to stop wasting my fucking time with these idiots on the forums. "

Quite offensive don't you think so? You deserve neg rep for that I think, but that's not for me to decide. I never asked how to avoid it, I merely was questioning why would that action be created like that. As well I am not halfwit or a noob which would mean stupid beginner and I am not that, you definitely need to learn manners and common sense before you talk to people and maybe get some social skills too. by the way I read your entire paragraph. Thank you everyone else though.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
WarManta said:
you definitely need to learn manners and common sense before you talk to people and maybe get some social skills too.

WarManta said:
What you said still looks like in jass, thanks though...

What do you mean, then, "it still looks like it's JASS"? To me it sounds like you're dismissing what I've said as "not relevant" based entirely on the fact that it contains certain JASS custom script lines. Also you can use the
tags to quote me next time.

Not to mention discussion of Blizzard's poor judgment in making some of the JASS API is not something that should be discussed in Triggers & Scripts, this section is for problems/news regarding Triggers & Scripts, not why natives do what they have been doing since Warcraft came out.

WarManta said:
Anybody know why the action move unit instantly always issues a stop order as it runs?

I answered your question on why that action stops units.

WarManta said:
I found out why spells and stuff can't be casted because of perodically interrupted orders from that gui action

Dude, in the several years that this site has been up and running this has been concluded time and time again. It's not my fault that you can't use the site's search feature.

WarManta said:
I always thought it paused the unit but what it seems to do is issue a stop order and then moves it...

Again, this isn't news.

WarManta said:
Maybe detection of orders issued correctly causes the action to perform at its best to start? I doubt that, but I would prefer to hear your thoughts guys and girls.

Okay, now I kindly answered your question. I then proceeded to give you a solution (if you required it) to the problem, already knowing that you definitely did not use the search feature to look up similar problems that have already been documented on this site. Even after I've taken the time to address your problems, and supply you with an adequate solution, your response is:

WarManta said:
What you said still looks like in jass, thanks though...
What I was mainly asking was why would blizzard make a action as evil as that?

You clearly have a problem with my solution being in JASS. Anybody who can read English can see that. Not only that but your follow-up question has absolutely nothing to do with the thread title, instead it is another question that has even less to do with Triggers & Scripts. Not only that but you still didn't search for any previous information on the matter at hand.

WarManta said:
Quite offensive don't you think so?

It's better than having posts all over the Triggers & Scripts section that are merely asking people's personal opinions on why Blizzard did this and that. If you don't have an actual problem and you're just trying to discuss something for the sake of discussing, do not post in Triggers & Scripts. I try to help you and you tell me "Shh no I don't want a JASS answer plus I just want to talk about Blizzard".

Though, I digress. Perhaps just because you're not very familiar with everything doesn't warrant me treating you with disrespect.
 
Last edited:
Status
Not open for further replies.
Top