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 


Lua Information (Guides, Tutorials, etc.)
Goto page 1, 2  Next
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
atom0s
Moderator
Reputation: 198

Joined: 25 Jan 2006
Posts: 8515
Location: 127.0.0.1

PostPosted: Wed Jun 15, 2011 4:08 pm    Post subject: Lua Information (Guides, Tutorials, etc.) This post has 4 review(s) Reply with quote

What is Lua?
Quote:

Lua is a powerful, fast, lightweight, embeddable scripting language.

Lua combines simple procedural syntax with powerful data description constructs based on associative arrays and extensible semantics. Lua is dynamically typed, runs by interpreting bytecode for a register-based virtual machine, and has automatic memory management with incremental garbage collection, making it ideal for configuration, scripting, and rapid prototyping.

"Lua" (pronounced LOO-ah) means "Moon" in Portuguese. As such, it is neither an acronym nor an abbreviation, but a noun. More specifically, "Lua" is a name, the name of the Earth's moon and the name of the language. Like most names, it should be written in lower case with an initial capital, that is, "Lua". Please do not write it as "LUA", which is both ugly and confusing, because then it becomes an acronym with different meanings for different people. So, please, write "Lua" right!


Lua 5.1 Manual:
http://www.lua.org/manual/5.1/

Lua Programming Reference / Examples:
http://www.lua.org/pil/index.html

Official Lua Wiki:
http://lua-users.org/wiki/
The wiki has tons of examples, snippets, libraries and such which can come in handy when working on in depth projects.

Official Lua Mailing List:
http://www.lua.org/lua-l.html

Official Lua Forums:
http://forum.luahub.com/
The forums are a bit less then used. The Lua community still uses their mailing list more than the forums.


Performance Tips and Tricks:
http://www.lua.org/gems/sample.pdf
http://lua-users.org/wiki/OptimisationTips
http://stackoverflow.com/questions/89523/lua-patterns-tips-and-tricks

Metatables; Learn them, love them, use them..
http://www.lua.org/pil/13.html
http://phrogz.net/lua/LearningLua_MetatableEvents.html
http://phrogz.net/lua/LearningLua_ValuesAndMetatables.html
http://www.dreamincode.net/forums/topic/175747-lua-metatables-tutorial/

Examples and Tutorials:
http://lua-users.org/wiki/SampleCode
http://lua-users.org/wiki/TutorialDirectory

Small post to help get this section started.

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
InternetIsSeriousBusiness
Grandmaster Cheater Supreme
Reputation: 8

Joined: 12 Jul 2010
Posts: 1269

PostPosted: Wed Jun 15, 2011 7:35 pm    Post subject: Reply with quote

Nice thread, Wiccaan!

Newly created section too.
w00t!

_________________
FLAME FLAME FLAME!!!@@@
Back to top
View user's profile Send private message
Kurifodo
I post too much
Reputation: 23

Joined: 09 Oct 2008
Posts: 2782

PostPosted: Wed Jun 15, 2011 7:40 pm    Post subject: Reply with quote

This is interesting I think I will devote a lot of time over summer learning this new PL thanks alot Wiccaan!
_________________
Anon
Back to top
View user's profile Send private message
the the the
Master Cheater
Reputation: 46

Joined: 15 Jun 2008
Posts: 429

PostPosted: Wed Jun 15, 2011 8:13 pm    Post subject: Reply with quote

Yeah thanks. How will it be incorporated?
Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 198

Joined: 25 Jan 2006
Posts: 8515
Location: 127.0.0.1

PostPosted: Wed Jun 15, 2011 11:56 pm    Post subject: Reply with quote

wrote:
Yeah thanks. How will it be incorporated?


It already is in CE. Download CE 6.x and check out main.lua in the CE folder for more information regarding whats exposed.

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
atom0s
Moderator
Reputation: 198

Joined: 25 Jan 2006
Posts: 8515
Location: 127.0.0.1

PostPosted: Sun Dec 18, 2011 12:05 am    Post subject: Reply with quote

Lua 5.2 is now out officially. CE, as of this post, is still using 5.1 but if you wish to get familiar with the new version, you can find it here:

Lua 5.2 - Dec. 16, 2011
http://www.lua.org/ftp/lua-5.2.0.tar.gz

Notable Changes
  • yieldable pcall and metamethods
  • new lexical scheme for globals
  • ephemeron tables
  • new library for bitwise operations
  • light C functions
  • emergency garbage collector
  • goto statement
  • finalizers for tables


Lua 5.2 Reference Manual
http://www.lua.org/manual/5.2/

Incompatibilities, Things You Should Know When Upgrading
http://www.lua.org/manual/5.2/manual.html#8

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
Invader
Advanced Cheater
Reputation: 0

Joined: 19 Mar 2012
Posts: 78

PostPosted: Tue Aug 21, 2012 5:15 pm    Post subject: Reply with quote

thanks iam new in these lang
Back to top
View user's profile Send private message
the04riverrat
Advanced Cheater
Reputation: 1

Joined: 10 Oct 2012
Posts: 53

PostPosted: Thu Oct 18, 2012 12:22 am    Post subject: Reply with quote

Most Helpful!

Still a bit new to Lua coding.

But I have experience in Web coding.

Very Interested in expanding into Lua.

Thanks for the links!
Back to top
View user's profile Send private message
majmun
Newbie cheater
Reputation: 1

Joined: 22 Dec 2012
Posts: 15

PostPosted: Mon Dec 03, 2012 7:45 pm    Post subject: Re: Lua Information (Guides, Tutorials, etc.) Reply with quote

Your tutorial is goldmine.It'a honor to have you on this forum,thanks!
Back to top
View user's profile Send private message
hacker1000
How do I cheat?
Reputation: 0

Joined: 07 Mar 2014
Posts: 1

PostPosted: Mon Mar 10, 2014 12:43 pm    Post subject: Reply with quote

thanks bro i am new to lua
u helped me alot
thanks Very Happy
Back to top
View user's profile Send private message
Shadows_End
Cheater
Reputation: 0

Joined: 22 Aug 2014
Posts: 43
Location: Garbage Truck

PostPosted: Tue Dec 08, 2015 4:45 am    Post subject: Reply with quote

Thx for this great tut
_________________
I Know Everything About You Hitler O.O
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Nemexia55
Expert Cheater
Reputation: 0

Joined: 28 Jan 2014
Posts: 160

PostPosted: Mon Jan 18, 2016 9:13 am    Post subject: Reply with quote

hi
can you say how we can use lua in CE?
i really have no idea about lua's function in CE.
i havent seen a good TUT about how to use it...
somebody helppp

_________________
Back to top
View user's profile Send private message
Redouane
Master Cheater
Reputation: 3

Joined: 05 Sep 2013
Posts: 363
Location: Algeria

PostPosted: Mon Jan 18, 2016 10:30 am    Post subject: Reply with quote

Nemexia55 wrote:
hi
can you say how we can use lua in CE?
i really have no idea about lua's function in CE.
i havent seen a good TUT about how to use it...
somebody helppp


You can use it to make a trainer (or GUI),or to automate something,for example,auto-attach to a process (useful in a cheat table or trainer),almost everything that you can do with CE can be done with Lua.

You can also use it to make more complex auto assemble scripts.
This code:
Code:
 
00430000:
{$lua}
if getCEVersion() == 6.4 then
    return 'push esi';
else
    return 'mov eax,ecx';
end
{$asm}

would assemble push esi if CE's version is 6.4,and mov eax,ecx otherwise,this (kind of metaprogramming) is really useful in some cases.


Last edited by Redouane on Mon Jan 18, 2016 5:38 pm; edited 1 time in total
Back to top
View user's profile Send private message
ParkourPenguin
I post too much
Reputation: 137

Joined: 06 Jul 2014
Posts: 4250

PostPosted: Mon Jan 18, 2016 4:06 pm    Post subject: Reply with quote

Nemexia55 wrote:
can you say how we can use lua in CE?

Read main.lua in CE's directory.

_________________
I don't know where I'm going, but I'll figure it out when I get there.
Back to top
View user's profile Send private message
Nemexia55
Expert Cheater
Reputation: 0

Joined: 28 Jan 2014
Posts: 160

PostPosted: Wed Jan 20, 2016 4:39 am    Post subject: Reply with quote

So you mean i can hack even CE tutorials by this method?
How should i do it for lrvrl one?

_________________
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 1, 2  Next
Page 1 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