| 12-01-2008, 09:47 PM | #1 |
I'm trying to figure out how can you completely disable a player's ability to use a unit but still be able to select the unit like his own and hear the units talk. This was done in the map Castle Fight and is pretty interesting cause you can see the unit's stats but no command card or hotkeys! |
| 12-01-2008, 10:06 PM | #2 |
Stunning the unit and removing the buff effect? |
| 12-01-2008, 10:54 PM | #3 |
Doesn't the pause-unit action already achieve that? |
| 12-02-2008, 01:01 AM | #4 |
Castle Fight agent units have the 'ward' classification. They can be selected and issued 'smart' (right-click) orders; but their command interfaces are blacked-out. This is a guess: All deliberate AI Castle Fight agent unit orders are explicit - that is, not 'smart'. Players can ONLY issue 'smart' (right-click) orders to their units - as you may have noticed - because they are of the 'ward' classification as explained above. Maybe Castle Fight code detects these orders (A unit is issued an order; issued order is 'smart') and overrides/bypasses them by issuing a deliberate order. So, for the unit to be selectable and stuff, andaction-doing but not 'orderable', you must have a trigger that detects player-issued 'smart' orders, and responds to these events by overriding this by issuing a deliberate AI order. |
| 12-04-2008, 01:46 AM | #5 |
Hmm, but the right click would still be issued even though you override it so won't the move thing pop up (those arrows that pop up) when you right click anyways? |
| 12-04-2008, 02:29 AM | #6 | |
Quote:
Everything will happen as normal, the order will in fact e received and the unit will try to follow the order. The Trigger will catch the order, and before the unit has time to respond, the trigger will issue its orders. The sequence is chopped in the middle "Smart" order- Location Notifier- Vocal response- -TRIGGER Trigger orders carried out hope that is what you needed to know... (In simpler terms, You tell the unit what to do, but the trigger tells it to do something immediately after as if YOU had told it to do something immediately after (changed your order)) |
| 12-04-2008, 10:47 PM | #7 |
Yeah I get that, was just asking if the move command still show up as you right click, which does appearantly. But in castle fight, this wasn't possible, right click does not show! But anyways, I guess it's fine, I would just love to know how did Castle Fight completely removed it. |
| 12-05-2008, 01:16 AM | #8 |
By "move command" do you mean the little green arrows that show where you clicked? Because this method will remove the move UI ability from the unit and it won't ever actually move anywhere unless you do so with triggers. |
| 12-05-2008, 01:21 AM | #9 |
Although I highly doubt they did this, they could have removed the 'arrows generated on move' model, imported it, and they display it as an effect whenever a unit you can actually order is issued an order. But really, that's just wasteful, considering that there has to be a better way. Maybe they abuse a dummy player + shared control? |
| 12-05-2008, 09:43 PM | #10 | |
Quote:
YES! I'm pretty sure this is what I wanted. I want to remove a unit's ability to move on command but still command it with triggers but won't ever show up but at the same time, have a unit that the player CAN use that has the move command |
| 12-05-2008, 11:34 PM | #11 |
Then adding the ward classification and blocking the orders as fX_ said is exactly what you want. Trigger: TriggerOrder is some sort of boolean variable that you would set to true when you issue a "move" or "patrol" order and you don't want it to be blocked, then set it to false after issuing the order. As for removing the model, the method Here-b-Trollz outlined seems like it would be the best option, if in fact it is possible. |
| 12-06-2008, 11:57 AM | #12 |
The dummy allied player, or the "extract-remove-reimport-create via triggers"? The first one might work, and seems a lot less of a hassle. |
| 12-06-2008, 07:16 PM | #13 |
Dummy unit > no credit of killing since it's not 1 on 1 Removing the right click then remove the player commands > dude... you have your own units to control, you just killed your right click |
| 12-06-2008, 09:55 PM | #14 |
You're not removing right click, you're removing the green arrow model that shows where you clicked. This will not interfere with the ability to right-click and order units. (BTW, I still don't even know if this is possible) |
