Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


How can i make search box like this

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
anonoobz
How do I cheat?
Reputation: 0

Joined: 18 Aug 2020
Posts: 1
Location: Indonesia

PostPosted: Tue Aug 18, 2020 5:39 am    Post subject: How can i make search box like this Reply with quote

How can i make search box like this Confused Confused Confused Confused


Capture.PNG
 Description:
how can i make search box like this :?
 Filesize:  10.45 KB
 Viewed:  1132 Time(s)

Capture.PNG


Back to top
View user's profile Send private message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1668

PostPosted: Tue Aug 18, 2020 6:30 am    Post subject: Reply with quote

Maybe not exactly as you want, but this sample purpose is about filtering logic.

Code:
function createCListBox(Parent)
 local clb = createComponentClass('TCheckListBox', Parent)
 clb.Parent = Parent
 return clb
end

if f then f.destroy() end

f = createForm()

e = createEdit(f)
e.top = 10
e.left = 10
e.width = 200
e.Color = 0
e.Font.Color = 0xff
e.Font.Size = 14

a = createCListBox(f)
a.top = 50
a.left = 10
a.height = 150
a.width = 200
a.Color = 0
a.Font.Color = 0xff
a.Font.Size = 14
a.ScrollWidth = 10
a.Items.Clear()

local cheatlist = {
'Anti Asking',
'Anti Answering',
'Be Careful',
'Bad Argument',
'Bad Mention',
'Cheater',
'Close Case',
'Do Everything'
}

function lbCheck()
 local get_text = e.Text
 if get_text == nil or get_text == "" then
    a.clear()
 else
    filter_letter = string.sub(get_text, 1, 3)
    a.clear()
    for x = 1, #cheatlist do
        ls = string.sub(cheatlist[x],1,3)
        if string.lower(ls) == filter_letter or string.upper(ls) == filter_letter then
           a.Items.Add(cheatlist[x])
    end
  end
 end
end

f.Show()
e.OnChange = lbCheck

_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites