Author Topic: Total Conversion?  (Read 1883 times)

xilluzionsx

  • Newbie
  • *
  • Posts: 3
    • View Profile
Total Conversion?
« on: January 28, 2015, 01:29:41 pm »
Hello everyone! I am new and eager to learn this engine! I have a team of 4 people (including me) trying to create a total conversion, as in not using any Zelda lore. I am the designated coder for the project and I have some questions about this engine. First off, I have never coded ( or scripted I guess) in LUA before. It seems simple enough just need to look at some literature, but I am used to coding in C++. So that is just a little background knowledge about me.

Anyways, onto my questions!!

My first question lies with creating a whole new character from just using the LUA scripting language. Can this be done? I have looked over the documentation the past few days and noticed the "Custom Entity" (class?). By using that I am assuming I can program literally a knew character and not use the Hero Entity (class?), am I correct?

Then my second question consists of creating an attack for the new custom hero. Would I go about just defining it as a "Custom Entity" or am I able to create functions that the custom hero would call upon?

I am just not used to LUA scripting and how everything is linked together, so I am just trying to wrap my head around it. Thanks for looking at my questions and I hope any of you guys can help me out! Also in the next coming weeks I'll post in the Projects thread of my progress. Again thanks!

xilluzionsx

Christopho

  • Administrator
  • Hero Member
  • *****
  • Posts: 1179
    • View Profile
Re: Total Conversion?
« Reply #1 on: January 28, 2015, 01:53:51 pm »
Hi,
First, thanks for using Solarus!
The engine currently supports only one hero (playable character) with built-in actions, and a few things can be customized. Maybe this is enough for you, maybe not :)
If not, as discussed in another thread, it is theoretically possible to make a completely custom one. As a custom entity, yes. You would have to do everything in Lua: movements, collisions with obstacles, enemies, NPCs, etc.

Anyway, since you know C++ if will be very easy to learn Lua. I recommend the Programming in Lua book. The first edition of the book is freely available online at http://www.lua.org/pil/contents.html.

xilluzionsx

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Total Conversion?
« Reply #2 on: January 28, 2015, 03:12:33 pm »
Thanks for the quick response man! Then what would you suggest to adding new functions of the hero class? Pretty much I would like to add magic spells, so would I make them in the Equipment Item class for the hero to select and then make a Custom Entity to display the spell on the map when being used?

Thanks!

Christopho

  • Administrator
  • Hero Member
  • *****
  • Posts: 1179
    • View Profile
Re: Total Conversion?
« Reply #3 on: January 28, 2015, 04:09:35 pm »
If what you need is just adding magic spells, you don't have to change C++ code, this is doable in pure Lua. Create an equipment item in your quest and in the item script, make a custom entity corresponding to your magic effect, possibly with a special animation of the hero.

xilluzionsx

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Total Conversion?
« Reply #4 on: January 28, 2015, 04:39:02 pm »
That is what I was thinking, haha. Sorry about calling it a class, as I don't know what to call them (functions?). Anyways yea that is what I had in mind, but just wasn't quite sure if that is the proper way of doing it in LUA. Thanks man for the clarification! I am really excited to start working on this! I'll post up a demo video for everyone in the community to see what I have done in the projects thread some time this week.

Again thanks a lot man!

xilluzionsx

Christopho

  • Administrator
  • Hero Member
  • *****
  • Posts: 1179
    • View Profile
Re: Total Conversion?
« Reply #5 on: January 28, 2015, 05:04:02 pm »
Ok good :) Let's say "a Lua object" then :)

polyglot762

  • Newbie
  • *
  • Posts: 49
  • a Quirk Storm... a coming.
    • View Profile
Re: Total Conversion?
« Reply #6 on: June 10, 2015, 03:34:31 pm »
Looking forward to seeing that demo. 8)