Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG - <context.damager> is not recognized as a tag in if question #333

Closed
GomaTerzu opened this issue Aug 7, 2013 · 1 comment
Closed
Labels
Bug Denizen is misbehaving.

Comments

@GomaTerzu
Copy link
Contributor

I have this script:

"Schadensflag":
    type: world
    events:
        On player damaged by player:
            - if <player.is_online> flag player Logoutverbot:true duration:10s
            - if <context.damager.is_online> flag player:<context.damager> Logoutverbot:true duration:20s

and this Result:
As you can see damager=p@Formwandler get's recognized at the start, i also can narrate it. But as soon as i want to use it in an if question it does not work anymore

12:44:46 [INFO]  +> Executing 'Event': Type='On PLAYER damaged by PLAYER'
                   Script='SCHADENSFLAG(WORLD)'  Player='Goma_Terzu'
                   Context='{cause=ENTITY_ATTACK, damager=p@Formwandler,
                   entity=p@Goma_Terzu, damage=1.0}'
12:44:46 [INFO] +- Building event 'On PLAYER DAMAGED BY PLAYER' for
                   SCHADENSFLAG ------+
12:44:46 [INFO]  Starting InstantQueue
                   '3D19C644-CAF1-49B7-80F0-AA84B9CAC98C'
12:44:46 [INFO] +- Executing dCommand: if/Goma_Terzu ------+
12:44:46 [INFO] +> [Element] Filled tag <player.is_online> with 'true'.
12:44:46 [INFO]  Comparable 1: Comparable='Boolean(true)',
                   Operator='EQUALS', ComparedTo='Boolean(true)' -->
                   OUTCOME='true'
12:44:46 [INFO] +- Executing dCommand: FLAG/Goma_Terzu ------+
12:44:46 [INFO]  +> Executing 'FLAG': Name='LOGOUTVERBOT'  Type='PLAYER'
                   Action/Value='SET_VALUE(true)'  duration='10.0s'
                   Player='Goma_Terzu'
12:44:46 [INFO] +- Executing dCommand: if/Goma_Terzu ------+
12:44:46 [INFO]  ERROR! Invalid Player! 'context.damager' could not be
                   found. Has the player logged off?
12:44:46 [INFO] +> [Element] Filled tag <context.damager.is_online> with
                   'true'.
12:44:46 [INFO]  Comparable 1: Comparable='Boolean(true)',
                   Operator='EQUALS', ComparedTo='Boolean(true)' -->
                   OUTCOME='true'
12:44:46 [INFO] +- Executing dCommand: FLAG ------+
12:44:46 [INFO]  ERROR! Woah! Invalid arguments were specified!
12:44:46 [INFO]  +> MESSAGE follows: 'Specified PLAYER-type flag with no
                   valid Player reference.'
12:44:46 [INFO]  Usage: flag ({player}/npc/global)
                   [<name>([<#>])](:<action>)[:<value>] (duration:<value>)
@mcmonkey4eva
Copy link
Member

The error is in

flag player:<context.damager> Logoutverbot:true duration:20s

You can't specify a different entity in the flag command.

... But you should be able to after I commit this - flag update >:D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Denizen is misbehaving.
Projects
None yet
Development

No branches or pull requests

2 participants