Slap counter script doesn't apply condition

  • updated
  • Pending Customer

I created an event triggered by slapping certain unit for certain times.

Number value starts with 0

Slap counter script triggered "on slap"

Condition "is a unit" (manually selected from "Map Units" with the correct ID)

Action Add to number "Imp Slaps" by 1

when total is 7 an event is triggered.

But when testing the map, doesn't matter if I slap that spesific unit or even just right click anywhere on the map,

the slap counter is working and triggering the event.

Game Version:
Steam Public
Lee "Noontide" Moon
  • Pending Customer

I put together a test scenario as the following:

On Slap (Default)
Condition: Is of type (Worker)
Action: Increase Number (Number 1)
Add number to string. (Number 1 + String)
Send Chat Message (String)

In my tests with this setup the slap would increment the number correctly only for workers. Does this work for your case?

I also didn't find that it triggered on right clicks. Shouldn't be the case for sure. I'll see if we can review your map at some point. :)

Horned Reaper

I wanted this script to apply to a spesific unit, that's why the condition was set for "is unit" and selected from a party, which is spawned on start and the unit is renamed.

Perhaps that is the issue. Would you be so kind to test this particular setup with the given circumstances?