wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Warcraft III Modding > Developer's Corner > General Development
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 07-14-2015, 12:17 PM   #31
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

you have still not provided a way to intercept an automatic stop order and until you do i am getting nowhere.
andreasaspenberg is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 07-15-2015, 12:33 AM   #32
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

You can't intercept the automatic stop order because it is never fired. You can (as my last 2 posts explain) periodically check (e.g. every 0.02 seconds) if a units current order is 0 (the order id for just sitting around, e.g. after it has finished another order). If it is, and it's previous order (last time the trigger ran) wasn't 0, then you know it just finished it's last order and now should be transformed into the stationary unit.

You will not get anywhere with this design though, as I have also explained many times now...


I don't know how many more ways I can explain this to you...

Last edited by Fledermaus : 07-15-2015 at 12:35 AM.
Fledermaus is offline   Reply With Quote
Old 07-15-2015, 11:00 PM   #33
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

so tell me how to check the unit`s current order. i have tried triggers already but that trigger is broken. i therefore need a script. please provide it.
andreasaspenberg is offline   Reply With Quote
Old 07-16-2015, 12:40 AM   #34
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

native GetUnitCurrentOrder takes unit whichUnit returns integer

Or if you really want to make it hard for yourself:
Trigger:
Noob Time
Events
Conditions
Collapse Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Current order of (Picked unit)) Equal to (Order(0))
Then - Actions
Else - Actions
(That's under the "Order Comparison" option from the conditions list, incase you can't figure it out for when you can't figure it out).

Last edited by Fledermaus : 07-16-2015 at 07:22 AM.
Fledermaus is offline   Reply With Quote
Old 07-16-2015, 11:47 AM   #35
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

i have tested current order and it can not give abilities to units. the current order condition have 4 types of orders: harvest, move, smart and attack. i tried smart and it did nothing when the unit is just standing there. please provide a solution.
andreasaspenberg is offline   Reply With Quote
Old 07-16-2015, 08:02 PM   #36
Anitarf
Procrastination Incarnate


Development Director
 
Join Date: Feb 2004
Posts: 8,189

Submissions (19)

Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)

2008 Spell olympics - Fire - SilverApproved Map: Old School Alliance TacticsHero Contest #2 - 3rd PlaceSpell making session 2 winner

Default

Quote:
Originally Posted by andreasaspenberg
i have tested current order and it can not give abilities to units. the current order condition have 4 types of orders: harvest, move, smart and attack.
Harvest, move, smart and attack are just the four examples given by the description in the editor. You can use other order strings as well. However, while you can use any orderstring, you can't use an orderid with this GUI action like in the last example given by Fledrmaus. The only way to use orderids is through JASS:

Trigger:
Test
Events
Conditions
Collapse Actions
Custom script: if GetUnitCurrentOrder( udg_myUnit )==0 then
-------- Insert your actions here --------
Custom script: endif
__________________
Anitarf is offline   Reply With Quote
Old 07-16-2015, 09:26 PM   #37
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

Actually that GUI should work, the Order(0) will convert the string 0 into an integer 0. And the "Current order of unit" uses GetUnitCurrentOrder directly.

I can't make sense of what andreasaspenberg's latest problem with clear instructions is but am going to assume that (as always) he wants someone to write the code for him because he's too stupid to follow instructions.
I'm not going to waste anymore time writing code for you that I know you will eventually reject because it cannot be a complete solution. I have already given you a working solution, if you want to waste your time on something that you cannot get 100% working the way you want it, be my guest but don't expect me to help you without providing me with a way to fix the problem I've outlined.

Last edited by Fledermaus : 07-17-2015 at 12:36 AM.
Fledermaus is offline   Reply With Quote
Old 07-17-2015, 12:36 AM   #38
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

order(0) worked. was that really so difficult to provide? i found one issue. order(0) is any order and not just no order. do you have any solution to that issue?

Last edited by andreasaspenberg : 07-17-2015 at 12:45 AM.
andreasaspenberg is offline   Reply With Quote
Old 07-17-2015, 12:40 AM   #39
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

Quote:
Originally Posted by andreasaspenberg
order(0) worked. was that really so difficult to provide?
Seriously, what the actual fuck? The GUI example I posted was using Order(0)... How did I not provide it when that's what I used in the example...

Let's count the number of times I've told you to check for order id 0:

Quote:
Originally Posted by Fledermaus
I think you could catch that if you really wanted (periodically check when GetUnitCurrentOrder changes to 0) but there is still the problem that I have mentioned multiple times now.

Quote:
Originally Posted by Fledermaus
Ok, since you couldn't read my last post I'll try again.

When a unit finishes another order (e.g. move to a location) the result from GetUnitCurrentOrderId changes from the order id for move to 0.
You could periodically check all units you care about. Store their previous order id. Check this against their current GetUnitCurrentOrderId, if their current order id is 0, they have finished their previous order.

You will still not be able to tell when your "stationary" unit auto acquires a target (e.g. random enemy moving within their acquire range.
If your "stationary" unit can't attack that won't be a problem, however if it gets attacked and flees (like a peasant etc) you will also be unable to capture that order.

So really, this design won't work and you should just use the working solution I have already provided you.

Quote:
Originally Posted by Fledermaus
You can't intercept the automatic stop order because it is never fired. You can (as my last 2 posts explain) periodically check (e.g. every 0.02 seconds) if a units current order is 0 (the order id for just sitting around, e.g. after it has finished another order). If it is, and it's previous order (last time the trigger ran) wasn't 0, then you know it just finished it's last order and now should be transformed into the stationary unit.

You will not get anywhere with this design though, as I have also explained many times now...


I don't know how many more ways I can explain this to you...

Quote:
Originally Posted by Fledermaus
native GetUnitCurrentOrder takes unit whichUnit returns integer

Or if you really want to make it hard for yourself:
Trigger:
Noob Time
Events
Conditions
Collapse Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Current order of (Picked unit)) Equal to (Order(0))
Then - Actions
Else - Actions
(That's under the "Order Comparison" option from the conditions list, incase you can't figure it out for when you can't figure it out).

I didn't know if it was a GUI function but I used my brain and went:
  • Ok, I'm comparing a units current order to 0 - that sounds like a condition
  • Guess I'll look on the conditions list for "Order". That makes sense because it's about a units current order.
  • Cool, the "Order" category exists now to see if there is something similar to the native "GetUnitCurrentOrder"
  • Yes, there is "Current order of unit" that looks right.
  • Ok, what can I compare that too? There is an "Order" option, that sounds right.
  • Can I put 0 in it? Yes. Cool. Looks done.
  • Better just check it makes sense by converting it into jess. Yup, the functions do what I expected. Cool that should work

Last edited by Fledermaus : 07-17-2015 at 01:00 AM.
Fledermaus is offline   Reply With Quote
Old 07-17-2015, 03:09 AM   #40
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

Quote:
Originally Posted by andreasaspenberg
i found one issue. order(0) is any order and not just no order. do you have any solution to that issue?
It really isn't. Post your code so I can tell you what you're doing wrong. Or you could try debugging it yourself.
...Sorry, don't know what I was thinking there, post your code.

Last edited by Fledermaus : 07-17-2015 at 03:12 AM.
Fledermaus is offline   Reply With Quote
Old 07-17-2015, 12:19 PM   #41
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

i solved it myself by making it check specific orders before exceuting the action. i think you should be nicer to me rather than think that i am stupid. i only come here when i am completely stuck.(when none of my solutions work.)
andreasaspenberg is offline   Reply With Quote
Old 07-17-2015, 04:42 PM   #42
moyack
Evil Emoticon
 
moyack's Avatar


Respected User
Project Leader: PoC
 
Join Date: Jan 2006
Posts: 3,279

Submissions (17)

moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)

AI Tournament #2 - 2nd PlaceHero Contest - Second place

Send a message via MSN to moyack
Default

Quote:
Originally Posted by andreasaspenberg
i solved it myself by making it check specific orders before exceuting the action. i think you should be nicer to me rather than think that i am stupid. i only come here when i am completely stuck.(when none of my solutions work.)
andreas, your problem is the way you request the help. Learn to use polite requests and avoid to speak as a bot. Remember that we're not seeing your face and your writing gives the idea that you see us as people that HAVE to help you, as we work for you.
moyack is offline   Reply With Quote
Old 07-17-2015, 10:31 PM   #43
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

i am polite. i am using please in almost every request. i have now done some research and it is possible to make a unit activate bear form with a move order and transform, then move.
andreasaspenberg is offline   Reply With Quote
Old 07-17-2015, 10:31 PM   #44
Fledermaus
default string
 
Fledermaus's Avatar
 
Join Date: May 2006
Posts: 705

Submissions (1)

Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)Fledermaus is a jewel in the rough (194)

Send a message via MSN to Fledermaus
Default

Quote:
Originally Posted by andreasaspenberg
i think you should be nicer to me rather than think that i am stupid. i only come here when i am completely stuck.(when none of my solutions work.)
If it looks like a duck, walks like a duck and quacks like a duck...

Quote:
Originally Posted by andreasaspenberg
i am polite. i am using please in almost every request.
Just saying please doesn't make you polite. Your post are arrogant as fuck and you never show any gratitude after people have helped you. You never admit you are wrong after being proved wrong. You never provide any evidence for you ridiculous claims that something someone has told you is wrong or broken (when it's just you doing it wrong).

As an example I'll go through this thread from my perspective so that you can see what it's like:
  • New topic created by andreasaspenberg. Ok, let's check out what he wants this time.
  • Ok, he claims to have started a solution, would have been nice if he'd posted the code so I could take a look at how he's trying to do it to see if I add something to his approach (or suggest a better way). There is some ambiguity in his request though so I'll just get some clarification.
  • Ok he's given me clarifications on how he wants it to work. From previous experience in trying to do something similar myself I know that the approach he is taking wont work. I'll explain this to him and offer a suggestion on a better approach that will actually work 100%.
  • Ok, he didn't really say anything about my explanation of why it wont work with orders and the better approach being using x/y position. He did say that he would prefer to use it with Bear Form rather than Chaos Morph.
  • Well, I got bored so I coded the system for him. I had fun making funny variable names. I tried making it work with Bear Form rather than Chaos Morph but it didn't really work because he "can't" use vJass so I can't use the amazing LastOrder (and I'm not going to waste my time converting it to jass).
  • He claims he can't open a map made with the vanilla editor... Ok, is he trolling me? He also makes some ridiculous claim that jass written in a third party editor is illegal and he'll die or something if he uses it. Yeah, he has to be trolling... No one can be that stupid...
  • I realize that all code he's gotten from people from this website was probably written in a third party editor, therefor making it illegal in his eyes. I point this out because I really can't understand how he can believe this...
  • He responds with "blizzard have said nothing about third party sites or third party code, only third party programs and that i do not use". Ok, that makes sense but then why the fuck did he say this earlier "there several types of jass: one is typed in without the use of a third party program and therefore legal, others are typed in through the use of a third party program and therefore illegal"? Those 2 statements contradict each other... I don't even.
  • He ignores me and asks for a solution (even though I've already provided one).
  • I decide fuck it, I'll paste the code for him so he has no excuse not to use it. I'm a little annoyed so I make fun of him with some observational humor in my instructions on how to get it working in his map.
  • He ignores it, saying he wants to use Bear Form. Ok, I mean I already said I tried it with Bear Form and couldn't get it to work. Whatever, I'll explain again why it wont work with Bear Form.
  • He tells me why he thinks it'll work with Bear Form and catching orders. He doesn't offer anything to disprove my claims that it wont work with Bear for and catching orders. I tell him again that I have already said it wont work with order catching.
  • He flat out claims I am wrong. Offering no evidence or code. [sarcasm]Oh cool, maybe he fixed the blizzard bug that I fucking told him about as a reason why it wont work.[/sarcasm]
  • He sticks to his guns while still showing no evidence/code that proves he is right and that there is a way around the bug I have mentioned.
  • He then asks for a solution to one of the problems - not being able to intercept when a unit finishes it's current order and stops. (Wow, sure sounds like he has a working solution that fixes these issues).
  • I tell him a rough outline of how I would solve that problem but point out that there is still the other problem you can't solve.
  • He openly ignores the fact that there is another problem down the line and demands (oh but he said please so it's ok) a solution to the no order when stopping problem.
  • Ok well I guess my last post was a little vague, I'll repost it again in more detail. Maybe then he can figure it out.
  • "you have still not provided a way to intercept an automatic stop order and until you do i am getting nowhere."
    Yes, my post telling you that you cannot intercept the automatic stop order but telling you how to figure out when a unit has stopped doesn't do that at all... Can he not read?
  • Ok third time's the charm. Let's explain it one more time. Surely then he can figure it out right?
  • "so tell me how to check the unit`s current order. i have tried triggers already but that trigger is broken. i therefore need a script. please provide it."
    Nope, guess I was wrong. I clearly need to write the fucking thing for him because he's incapable of anything. Fuck.
  • Well I only know the native GetUnitCurrentOrder. I'll tell him that. Argh but he only uses GUI... Fine I'll look in the editor and check if there is a GUI equivalent. There is, I'll post that too.
  • "i have tested current order and it can not give abilities to units. the current order condition have 4 types of orders: harvest, move, smart and attack. i tried smart and it did nothing when the unit is just standing there. please provide a solution."
    Ok so he managed to find the Order condition in the editor. That's a good start. He also realized that it doesn't give a unit an ability - good, he's not trying to use the "Unit - Add Ability" action, that's not the right function at all!
    What's next? Oh he says it only works with harvest, move, smart and attack... I mean, he couldn't read that the "Order()" function's description says "Example order strings: 'harvest', 'move', 'smart', 'attack'". Ok maybe that's not fair, he could read some of the words but clearly missed the Example. He also didn't seem to think that if you could only use those 4 order strings it would be a dropdown list of the 4 order strings rather than a fucking string input field where you can put whatever the fuck you want into it.
    But he claimed to have tested it... Clearly...
  • "order(0) worked. was that really so difficult to provide? i found one issue. order(0) is any order and not just no order. do you have any solution to that issue?" ...................... Ok he's finally realized he needs to compare the units current order to Order 0. That's a start I guess... He clearly hasn't tested it properly though because he thinks that any order is Order 0 as well as itself (which doesn't make sense at all). At a guess I would say he's comparing the wrong unit (so it's probably pointing to a null unit, which I would imagine has a current order of 0).
  • "i solved it myself by making it check specific orders before exceuting the action. i think you should be nicer to me rather than think that i am stupid. i only come here when i am completely stuck.(when none of my solutions work.)"
    Holy shit. I don't even know what he's saying here. He probably hasn't even got it working but at this point I don't give a shit anymore, he's been such a fucking pain in the ass.
  • And here we are.

I hope that helps you see things from my perspective.
I will be nice to you when you stop acting like an arrogant idiot. I will stop calling you an idiot when you show me that you are not.


[/rant]

Last edited by Fledermaus : 07-18-2015 at 12:07 AM.
Fledermaus is offline   Reply With Quote
Old 07-18-2015, 03:49 PM   #45
andreasaspenberg
User
 
Join Date: Jul 2007
Posts: 147

andreasaspenberg is on a distinguished road (12)

Default

you are clearly trying to hurt my feelings but as i have none, your efforts are in vain.
andreasaspenberg is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off


All times are GMT. The time now is 10:27 PM.


Affiliates
The Hubb The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2018, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services