Yeah, so I'm trying to understand(get help) with why my trigger isn't working as intended. I want it so that if a character has a certain item(in INV) and they used a command then it will trigger. I've looked up the different variables on the DG site and none seem to work. Could I please get help(and an explanation)?
Name: 'Sun Stone/Dial Trigger', VNum: [63500], RNum: [ 242]
Trigger Intended Assignment: Rooms
Trigger Type: Command , Numeric Arg: 100, Arg list: reflect
Here is my first attempt at the trigger.
Code:
if (%cmd% == reflect)
if (%arg% == stone)
if (%object.vnum% == 63502)
wait 1 s
%teleport% %actor% 63541
%send% %actor% The trigger successfully works!
end
end
end
When you get to the if obj.vnum part it doesn't work. The first two IFs work but the last(third) one doesn't
Second variation of the trigger
Code:
if (%cmd% == reflect)
if (%arg% == stone)
if (%char.inventory(63502)%)
wait 1 s
%teleport% %actor% 63541
%send% %actor% The trigger successfully works!
end
end
end
And then I found something interesting/odd
Code:
if (%cmd% == reflect)
if (%arg% == stone)
if (%object.vnum% != 63502)
wait 1 s
%teleport% %actor% 63541
%send% %actor% The trigger successfully works!
end
end
end
The trigger actually fires and works(I am teleported) but this works if you have the item(63502) in your INV or even if you don't have it. So it's not what I want but it only confuses me more since I would expect it to not work if you have the item in your INV( due to being "!="); so I'd also really like help with understading the difference between "==" "!=".
My understanding
== : You need that EXACT level/item/mob/etc to work
!= : You need anything BUT that level/item/mob/etc