Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- DPIMultiplier=getScreenDPI()/96
- num=7
- if srcfrm1 then srcfrm1.Destroy() srcfrm1=nil end
- srcfrm1=createForm()
- srcfrm1.height=355*DPIMultiplier srcfrm1.width=320*DPIMultiplier srcfrm1.left=424*DPIMultiplier srcfrm1.top=172*DPIMultiplier
- srcfrm1.PopupMode=0 srcfrm1.caption="CE Forum: View User Posts!"
- srcfrm1.Position="poDesktopCenter" srcfrm1.BorderStyle=1
- srcfrm1.Font.Style="" srcfrm1.Font.Size=12
- -------------------------
- local srcTbl = {}
- ----------------------- srcTbl.lbl1 -----
- srcTbl.lbl1=createLabel(srcfrm1)
- srcTbl.lbl1.AutoSize=true
- srcTbl.lbl1.height=19*DPIMultiplier srcTbl.lbl1.width=86*DPIMultiplier srcTbl.lbl1.left=16*DPIMultiplier srcTbl.lbl1.top=15*DPIMultiplier
- srcTbl.lbl1.caption="User Name: "
- srcTbl.lbl1.alignment="taLeftJustify"
- -----------------------
- ----------------------- srcTbl.edt1 -----
- srcTbl.edt1=createComboBox(srcfrm1)
- srcTbl.edt1.AutoSize=false
- srcTbl.edt1.height=22*DPIMultiplier srcTbl.edt1.width=192*DPIMultiplier srcTbl.edt1.left=109*DPIMultiplier srcTbl.edt1.top=15*DPIMultiplier
- srcTbl.edt1.ReadOnly=false srcTbl.edt1.Style="csDropDown" srcTbl.edt1.Font.Size=9
- -----------------------
- ----------------------- srcTbl.btn1 -----
- srcTbl.btn1=createButton(srcfrm1)
- srcTbl.btn1.AutoSize=false
- srcTbl.btn1.height=25*DPIMultiplier srcTbl.btn1.width=300*DPIMultiplier srcTbl.btn1.left=10*DPIMultiplier srcTbl.btn1.top=50*DPIMultiplier
- srcTbl.btn1.caption="Open the search result in Browser!"
- -----------------------
- ----------------------- srcTbl.lbl2 -----
- srcTbl.lbl2=createLabel(srcfrm1)
- srcTbl.lbl2.AutoSize=false
- srcTbl.lbl2.height=24*DPIMultiplier srcTbl.lbl2.width=300*DPIMultiplier srcTbl.lbl2.left=10*DPIMultiplier srcTbl.lbl2.top=87*DPIMultiplier
- srcTbl.lbl2.caption="List of available pages:"
- srcTbl.lbl2.alignment="taCenter"
- srcTbl.lbl2.OptimalFill=true srcTbl.lbl2.Font.Size=11
- -----------------------
- ----------------------- srcTbl.lbl3 -----
- srcTbl.lbl3=createLabel(srcfrm1)
- srcTbl.lbl3.AutoSize=false
- srcTbl.lbl3.height=24*DPIMultiplier srcTbl.lbl3.width=160*DPIMultiplier srcTbl.lbl3.left=10*DPIMultiplier srcTbl.lbl3.top=122*DPIMultiplier
- srcTbl.lbl3.caption="Autor/User:"
- srcTbl.lbl3.OptimalFill=true srcTbl.lbl3.Font.Size=11
- -----------------------
- ----------------------- srcTbl.Cbx1 -----
- srcTbl.Cbx1=createComboBox(srcfrm1)
- srcTbl.Cbx1.AutoSize=true
- srcTbl.Cbx1.height=27*DPIMultiplier srcTbl.Cbx1.width=130*DPIMultiplier srcTbl.Cbx1.left=180*DPIMultiplier srcTbl.Cbx1.top=120*DPIMultiplier
- srcTbl.Cbx1.Font.Size=9 srcTbl.Cbx1.OptimalFill=true
- srcTbl.Cbx1.ReadOnly=true srcTbl.Cbx1.Style="csDropDownList"
- -----------------------
- -----------------------
- local nextLeft = 10*DPIMultiplier
- local nextTop = 5*DPIMultiplier
- local pages22= 0
- local browser1 = "chrome.exe"
- --srcTbl.edt1.text="mgr.inz.Player"
- -----------------------
- function createScrollBox(Parent)
- local box = createComponentClass('TScrollBox', Parent)
- box.Parent = Parent
- return box
- end
- function LoadUrl(link)
- local int=getInternet()
- s=int.getURL(link)
- int.destroy()
- return s
- end
- -----------------------
- srcTbl.Scrbx1=createScrollBox(srcfrm1)
- srcTbl.Scrbx1.AutoSize=false
- srcTbl.Scrbx1.height=180*DPIMultiplier srcTbl.Scrbx1.width=300*DPIMultiplier srcTbl.Scrbx1.left=10*DPIMultiplier srcTbl.Scrbx1.top=160*DPIMultiplier
- srcTbl.Scrbx1.Color=10395294 srcTbl.Scrbx1.Font.Style="fsBold" srcTbl.Scrbx1.Font.Size=10
- -----------------------
- function pageClear()
- nextTop=5*DPIMultiplier
- nextLeft = 10*DPIMultiplier
- srcTbl.Scrbx1.Destroy() srcTbl.Scrbx1=nil
- srcTbl.Scrbx1=createScrollBox(srcfrm1)
- srcTbl.Scrbx1.AutoSize=false
- srcTbl.Scrbx1.height=180*DPIMultiplier srcTbl.Scrbx1.width=300*DPIMultiplier srcTbl.Scrbx1.left=10*DPIMultiplier srcTbl.Scrbx1.top=160*DPIMultiplier
- srcTbl.Scrbx1.Color=10395294 srcTbl.Scrbx1.Font.Style="fsBold" srcTbl.Scrbx1.Font.Size=10
- end
- -----------------------
- srcTbl.edt1.Clear()
- srcTbl.edt1.Items.Add("") -- Search edit ..
- srcTbl.edt1.Items.Add("Dark Byte") --443
- srcTbl.edt1.Items.Add("mgr.inz.Player") --212
- srcTbl.edt1.Items.Add("atom0s") --191
- srcTbl.edt1.Items.Add("Recifense") --163
- srcTbl.edt1.Items.Add("Zanzer") --126
- srcTbl.edt1.Items.Add("ParkourPenguin") --119
- srcTbl.edt1.Items.Add("++METHOS") --81
- srcTbl.edt1.ItemIndex=0
- ------------------------
- ------------------------
- srcTbl.Cbx1.Clear()
- srcTbl.Cbx1.Items.Add("Select Browser")
- srcTbl.Cbx1.Items.Add("Google Chrome")
- srcTbl.Cbx1.Items.Add("Mozilla Firefox")
- srcTbl.Cbx1.Items.Add("Microsoft Edge")
- srcTbl.Cbx1.Items.Add("Opera")
- srcTbl.Cbx1.Items.Add("Internet Explorer")
- srcTbl.Cbx1.Items.Add("Maxthon")
- srcTbl.Cbx1.Items.Add("Pale Moon")
- srcTbl.Cbx1.ItemIndex=0
- srcTbl.Cbx1.OnChange=function()
- local indd1=srcTbl.Cbx1.ItemIndex
- if indd1==0 then browser1 = "chrome.exe" end --default
- if indd1==1 then browser1 = "chrome.exe" end
- if indd1==2 then browser1 = "firefox.exe" end
- if indd1==3 then browser1 = "msedge.exe" end
- if indd1==4 then browser1 = "opera.exe" end
- if indd1==5 then browser1 = "iexplore.exe" end
- if indd1==6 then browser1 = "Maxthon.exe" end
- if indd1==7 then browser1 = "palemoon.exe" end
- end
- function crtLabel(cpt,idx,idx2,ops)
- titleLbl=createLabel(srcTbl.Scrbx1)
- if nextLeft==270*DPIMultiplier then nextLeft=10*DPIMultiplier nextTop=tonumber(nextTop) + 20*DPIMultiplier end
- titleLbl.Left=tonumber(nextLeft)
- nextLeft = tonumber(nextLeft) + 65*DPIMultiplier
- --print(nextLeft)
- titleLbl.Top=nextTop
- titleLbl.Caption="Page #"..idx
- titleLbl.Font.Size=10
- titleLbl.height=20*DPIMultiplier
- titleLbl.width=660*DPIMultiplier
- titleLbl.Tag=650
- if ops==3 then
- titleLbl.AutoSize=false
- titleLbl.width=280*DPIMultiplier
- titleLbl.alignment=2*DPIMultiplier
- titleLbl.Caption=cpt
- titleLbl.height=24*DPIMultiplier
- titleLbl.Top=5*DPIMultiplier
- titleLbl.OptimalFill=true
- nextTop=40*DPIMultiplier
- pages22=0
- end
- if ops==1 then
- titleLbl.Font.Color=16711680
- titleLbl.Font.Style="fsBold,fsUnderline"
- titleLbl.Cursor = -21
- name1=srcTbl.edt1.Text
- titleLbl.OnClick=function()
- lnk="https://forum.cheatengine.org/search.php?search_author="..name1.."&start="..idx2
- shellExecute(browser1,lnk) end
- end
- if ops==2 then
- titleLbl.Font.Color=16711680
- titleLbl.Font.Style="fsBold,fsUnderline"
- titleLbl.Cursor = -21
- name1=srcTbl.edt1.Text
- titleLbl.OnClick=function()
- lnk="https://forum.cheatengine.org/search.php?search_author="..name1.."&start="..idx2
- shellExecute(browser1,lnk) end
- end
- end
- function urlFormats(str)
- str = string.gsub (str, "([^0-9a-zA-Z !'()*._~-])", -- locale independent
- function (c) return string.format ("%%%02X", string.byte(c)) end)
- str = string.gsub (str, " ", "+")
- return str
- end
- function search()
- pgIdx = 0
- pfind1 = 0
- pfind2 = 0
- if srcTbl.edt1.Text=="" then
- showMessage("Type a username in the box and try again!")
- else
- url1 = LoadUrl("https://forum.cheatengine.org/search.php?search_author="..urlFormats(srcTbl.edt1.Text).."&start="..pages22)
- if url1 then
- url2 = (url1):gsub("&","&")
- sl1=createStringList()
- sl1.Text=url1
- cnt1 = strings_getCount(sl1)-1
- for i=0, strings_getCount(sl1)-1 do
- art1=(sl1[i]):gsub(" ", ""):gsub(" ", ""):gsub(" ", ""):gsub(" ", ""):gsub(" ", "")
- art22 = (art1):match([[class="maintitle">(.*)</span><br]])
- if art22~=nil then
- srcTbl.lbl2.caption=art22
- pfind2 = tonumber((art22):match([[found (.*) matches]]))
- end
- art23,art24 = (art1):match([[class="name"><b><a href="(.*)">(.*)</a></b></span><br />]])
- if art23~=nil then
- srcTbl.lbl3.caption="Visit Profile: "..art24
- srcTbl.lbl3.Font.Color=16711680
- srcTbl.lbl3.Font.Style="fsBold,fsUnderline"
- srcTbl.lbl3.Cursor = -21
- lnk11=(art23):gsub("amp;","")
- --print(art23.." - "..art24)
- srcTbl.lbl3.OnClick=function()
- shellExecute(browser1,[[https://forum.cheatengine.org/]]..lnk11)
- end
- end
- art2 = (art1):match([[nav">(.*)</b></span]]) --sub(1,17)
- --print(art2)
- if art2~=nil then
- pfind = (art2):gsub([[<b>]],""):gsub([[</b>]],"")
- pfind1 = tonumber((pfind):match([[of (.*)]]))
- crtLabel(pfind,0,0,3)
- end
- end
- sl1.Destroy()
- nextLeft = 10*DPIMultiplier
- pages22=0
- for i=1, tonumber(pfind1) do
- if i==tonumber(pfind1) then
- pf2 = math.floor(tonumber(pfind2) / 15)
- pages22=pf2*15
- crtLabel("Pages",i,pages22-15,1)
- else
- crtLabel("Pages",i,pages22,2)
- pages22=i * 15
- end
- end
- end
- end
- end
- srcTbl.btn1.OnClick=function()
- pageClear()
- pages22 = 0
- search()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement