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 


Cheat Engine Forum Index
PostGo back to topic
predprey
Master Cheater
Reputation: 24
Joined: 08 Oct 2015
Posts: 486

PostPosted: Wed Oct 05, 2016 8:18 am    Post subject: Custom Lua Script Templates

As suggested by ++METHOS, adds template function to cheat table Lua script, similar to the awesome "Custom AOB Injection Templates" by mgr.inz.Player.

Suggestions welcome for any additional keywords, templates or features.
Post your own templates below if you want me to merge it into main branch.

Adding Custom Scripts
Method 1:
Update Lua file with another entry, inside myLuaScriptTemplates.Templates:
Code:
{
displayName="Name for Lua script template",
templateSections=
[==[
--Write script here--
]==]
},

To create template groups:
Code:
{
displayName="Name for template group",

{
displayName="Name for Lua script template",
templateSections=
[==[
--Write script here--
]==]
}

},


Method 2:
Save script as a .lua file in CEDirectory\autorun\templates folder. Create new folder if necessary.
Display name will be taken from file name.
Sub-directories can be used to create template groups.
Group name is taken from sub-directory name.

Example of a template group here.
Drop folder into templates folder.

Keywords are:
%processName% - Self explainable
%placeholder_XXX% - Prompts the user for replacement string. Cancelling prompt would stop generating the template. Underscores in "XXX" section are replaced with spaces allowing for multi-worded tags. Prompts repeatedly until all unique placeholders have a replacement string.

To install:
1. Drop .lua file in CEDirectory\autorun folder

Quote:
Update 1:
- Added support for loading Lua scripts from templates folder as suggested by Dark Byte.

Update 2:
- Added a new keyword.
- Added a few new templates from Zanzer.
- Added support for creating template groups.
- Added support for loading templates in sub-directories inside templates folder.

Update 3:
- Major update to localize all functions to avoid conflicts between extensions due to similar names, especially commonly used library functions.


Credits and Thanks to:
mgr.inz.Player
Dark Byte
Zanzer

_________________
Hitler!
Dropdown Menu Lists Editor - Create and add dropdown lists easily. Save time and reduce table sizes
CEnhancer - Collection of extensions that improves CE's inbuilt functionality


Last edited by predprey on Sat Oct 08, 2016 12:42 am; edited 10 times in total
Back to top
View user's profile Send private message
Post reviews:   Approve 2
Author Review
++METHOS
Review: Approve
Post reference:
ReviewPosted: Tue Nov 22, 2016 3:24 pm

I forgot to +rep you for this.
Back to top
View user's profile Send private message
jgoemat
Review: Approve
Post reference:
ReviewPosted: Wed Jun 06, 2018 5:29 pm

Nice!
Back to top
View user's profile Send private message
Display:  
Cheat Engine Forum Index


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites