Design Patterns - Lua

Hi,

Lately I did 25 design patterns samples for Corona-Lua.

Part of them is implemented from Actionscript 3.0 samples by JohnLindquist. For these I have attached youtube links to John’s YouTube channel.

Rest of them is made from scratch by me, some based on a standard samples for C++ etc. and implemented for Corona.

It is not a tutorial at the moment, because I had no time yet to do it (hopefully coming soon), so attached links should be really helpful thought. 

Some of the patterns like FluentBuilder or Iterator are very simple, so everyone will easily get an idea how it works even without any further explanations.

All the patterns are here: 


https://github.com/sebastianlis/DesignPatterns-in-Lua-Using-CoronaSDK


Full list of the implemented patterns on GitHub

  1. AbstractFactory

https://www.youtube.com/watch?v=N8_wwa90tzM&index=13&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

  1. Adapter

https://www.youtube.com/watch?v=hvpXKZhNINc&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=15

  1. Bridge

  2. Builder

https://www.youtube.com/watch?v=WrCbqlN4uXg&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=16

  1. ChainOfResponsibility

https://www.youtube.com/watch?v=O28YpB4fo18&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=9

https://www.youtube.com/watch?v=8aESixq2FWA&index=10&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

https://www.youtube.com/watch?v=EtR2dVXdVGo&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=11

  1. Command

https://www.youtube.com/watch?v=l0P8q0gWsR8&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=1

  1. Composite

  2. Decorator

https://www.youtube.com/watch?v=17XTOODeWQE&index=2&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

  1. Facade

  2. FactoryMethod

  3. FluentBuilder

12)Flyweight

  1. Interpreter

  2. Iterator

  3. Mediator

https://www.youtube.com/watch?v=lsrbDkW7pVw&index=7&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

  1. Memento

https://www.youtube.com/watch?v=0eOMPadRNmI&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=3

  1. Observer

  2. Prototype

19)Proxy

https://www.youtube.com/watch?v=WcAV9rOGjxw&index=4&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

  1. Singleton

  2. State

https://www.youtube.com/watch?v=yZt7mUVDijU&index=8&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM

  1. Strategy

https://www.youtube.com/watch?v=MOEsKHqLiBM&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=6

  1. TemplateMethod

  2. Visitor

https://www.youtube.com/watch?v=KSEyIXnknoY&list=PLj_1FhRbJP_LEWYWJh3-OEkI-JegU5oMM&index=5

  1. MVC

This pattern I used in sample list from ‘OOP Samples for CoronaSDK’ project

GitHub: https://github.com/sebastianlis/OOP-Samples-for-Corona-SDK

GPlay: https://play.google.com/store/apps/details?id=com.gmail.lis.a.sebastian.oopsamplesforcoronasdk

Hope it will be useful for you :slight_smile:

Sebastian

Thank you Sebastian!  ActionScript 2.0 was my first object-oriented language and I played around with design patterns in AS3.  These look really cool, what a gift!

I am very glad that found it useful, enjoy :slight_smile:

Good work I just test, it’s work great and show a part of the corona power.

In addition of that, there are the “in app purchase” category, and I am new on that field. Your github code page linked to the app is very usefull.

It will be good to pinned that page and that app like " corona cannon" reference to learn Corona.

Glad to hear yvandotet :slight_smile:

Thank you Sebastian!  ActionScript 2.0 was my first object-oriented language and I played around with design patterns in AS3.  These look really cool, what a gift!

I am very glad that found it useful, enjoy :slight_smile:

Good work I just test, it’s work great and show a part of the corona power.

In addition of that, there are the “in app purchase” category, and I am new on that field. Your github code page linked to the app is very usefull.

It will be good to pinned that page and that app like " corona cannon" reference to learn Corona.

Glad to hear yvandotet :slight_smile: