Jump to content
  • 0

See Value and Send Text Detect


1x1

Question

How do i choose the selected results and detect if the value is targeted and do a trigger.

 

Example: I'll search and got 1 results, if the value is 1 then it will say gg.alert('Value is 1 Bye').

 

If the value is 2 then gg.alert('Unknown, Value is not 1').

 

Sorry for bad English.

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • Moderators
6 hours ago, 1x1 said:

How do i choose the selected results and detect if the value is targeted and do a trigger.

 

Example: I'll search and got 1 results, if the value is 1 then it will say gg.alert('Value is 1 Bye').

 

If the value is 2 then gg.alert('Unknown, Value is not 1').

 

Sorry for bad English.

This?

gg.searchNumber("2", gg.TYPE_DWORD)
count = gg.getResultsCount()
v = gg.getResults(count)
if v[1].value == 1 then -- On index 1, only check first value. Make a loop to check all.
	gg.alert("Value is 1 Bye")
else
	gg.alert("Unknown, Value is not 1")
end

 

Link to comment
Share on other sites

19 hours ago, Collen said:

This?

gg.searchNumber("2", gg.TYPE_DWORD)
count = gg.getResultsCount()
v = gg.getResults(count)
if v[1].value == 1 then -- On index 1, only check first value. Make a loop to check all.
	gg.alert("Value is 1 Bye")
else
	gg.alert("Unknown, Value is not 1")
end

 

Hell yah, thanks man

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.