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 


different text colors in one memo or caption
Goto page Previous  1, 2
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
Dark Byte
Site Admin
Reputation: 472

Joined: 09 May 2003
Posts: 25875
Location: The netherlands

PostPosted: Sat Jan 18, 2020 7:28 am    Post subject: Reply with quote

add an pb.OnPaint function where you call the rendering code again
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
.lua
Expert Cheater
Reputation: 1

Joined: 13 Sep 2018
Posts: 203

PostPosted: Sat Jan 18, 2020 7:35 am    Post subject: Reply with quote

Dark Byte wrote:
add an pb.OnPaint function where you call the rendering code again
Code:

pb.OnPaint=function()
  pb.Canvas.clear()
  pb.Canvas.textRect(rect,0,0,s)
end
Is that right
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 472

Joined: 09 May 2003
Posts: 25875
Location: The netherlands

PostPosted: Sat Jan 18, 2020 7:48 am    Post subject: Reply with quote

yes, but make sure that s is reachable from that context
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
.lua
Expert Cheater
Reputation: 1

Joined: 13 Sep 2018
Posts: 203

PostPosted: Sat Jan 18, 2020 7:53 am    Post subject: Reply with quote

Dark Byte wrote:
yes, but make sure that s is reachable from that context
It won't disappear now, no matter how I manipulate the form,Thank you very much for this example. I'd like to ask, color text can be used for d3dhook
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 472

Joined: 09 May 2003
Posts: 25875
Location: The netherlands

PostPosted: Sat Jan 18, 2020 7:57 am    Post subject: Reply with quote

.lua wrote:
I'd like to ask, color text can be used for d3dhook


Only if you output to a picture and then turn that picture into a texture and update the texture each time the text changes

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
.lua
Expert Cheater
Reputation: 1

Joined: 13 Sep 2018
Posts: 203

PostPosted: Sat Jan 18, 2020 8:11 am    Post subject: Reply with quote

Dark Byte wrote:
Only if you output to a picture and then turn that picture into a texture and update the texture each time the text changes
OK, I'll try. If I still don't understand, please give me some tips
Back to top
View user's profile Send private message
.lua
Expert Cheater
Reputation: 1

Joined: 13 Sep 2018
Posts: 203

PostPosted: Sun Jan 19, 2020 10:35 am    Post subject: Reply with quote

Dark Byte wrote:
yes, but make sure that s is reachable from that context
There is a new problem. When you draw color text to a control, other controls in the control are also cleared. It's no use using retain()
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
Goto page Previous  1, 2
Page 2 of 2

 
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