registerLuaFunctionHighlight

Want Cheat Engine to do something specific and no idea how to do that, ask here. (From simple scripts to full trainers and extensions)
Post Reply
S1N74X
Novice Cheater
Novice Cheater
Posts: 19
Joined: Wed Sep 15, 2021 4:25 pm
Reputation: 1

registerLuaFunctionHighlight

Post by S1N74X »

Hello,

are there any requirements for "registerLuaFunctionHighlight"
The Documentation just says "registerLuaFunctionHighlight(functionname): Makes the lua highlighter show the functionname as a functionkeyword"

Code: Select all

function myFunc(Parameters)
do some stuff
end

--register the function for highlight
registerLuaFunctionHighlight(myFunc)
After activating the functionscript, nothing happens. There is no highlighting as supposed.

Any usefull ideas or suggestions are welcome :)

User avatar
LeFiXER
Expert Cheater
Expert Cheater
Posts: 296
Joined: Wed Mar 24, 2021 9:35 am
Reputation: 121

Re: registerLuaFunctionHighlight

Post by LeFiXER »

It doesn't appear to be working but I don't think it's a huge issue because it's just function highlighting. You could always affix an underscore to function names that are to do with Lua.

S1N74X
Novice Cheater
Novice Cheater
Posts: 19
Joined: Wed Sep 15, 2021 4:25 pm
Reputation: 1

Re: registerLuaFunctionHighlight

Post by S1N74X »

LeFiXER wrote:
Tue Nov 30, 2021 3:51 pm
It doesn't appear to be working but I don't think it's a huge issue because it's just function highlighting. You could always affix an underscore to function names that are to do with Lua.
Thank you.
Maybe it will work in the Future.

Eric
Hall of Famer
Hall of Famer
Posts: 147
Joined: Thu Mar 02, 2017 11:01 pm
Reputation: 78

Re: registerLuaFunctionHighlight

Post by Eric »

it says functionname, not function

You use it like this:

Code: Select all

function myfunction()
end
registerLuaFunctionHighlight('myfunction')
from then on when you type myfunction in lua it will get highlighted as a function

S1N74X
Novice Cheater
Novice Cheater
Posts: 19
Joined: Wed Sep 15, 2021 4:25 pm
Reputation: 1

Re: registerLuaFunctionHighlight

Post by S1N74X »

Eric wrote:
Wed Dec 01, 2021 2:36 pm
it says functionname, not function

You use it like this:

Code: Select all

function myfunction()
end
registerLuaFunctionHighlight('myfunction')
from then on when you type myfunction in lua it will get highlighted as a function
Awesome. Works thank you.
Maybe they should write "functionname as string". Would be clearer.
If you come from C++, C# or Java a functionname is a functionname and not a string :)

Post Reply

Who is online

Users browsing this forum: No registered users