Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - TheNaiker

#1
Thanks, your second hint looks to be good. I typed this
Code: lua
function readDb (ID)
assert (package.loadlib("sqlite3.dll", "luaopen_luasql_sqlite3"))()  
env = luasql.sqlite3()
con = env:connect("test.db")
res = con:execute("create table person( id integer primary key,name text not null, email text, phone text)")
con:close()
env:close()
a = 12
return a 
end

And after compiling and running the "test.db" file has been created without error messages. (I used the A variable to see if Ags runs the script)
I will make further tests, but I am satisfied with this. Thanks again.
#2
Quote from: Monsieur OUXX on Wed 11/05/2016 09:30:08
Quote from: TheNaiker on Wed 11/05/2016 08:02:21
Hi,
sorry for writing in this old topic, but I have a problem with this plugin.
I have installed it correctly and it works fine with simple lua scripts. But now, in order to write my real code, I need another lua module (luasql.sqlite, exactly).
In this case, what should I do? I am not expert about how Lua Works and I haven't found any dll for that module; and If I am not wrong the modules I got must be installed directly into lua.

Can you give me any hint?

Thanks.
You'd be probably better off asking on the Lua forums, but I'm sure Calin Leafshade will help if he sees your update (did you try PM'ing him?)

I've done that some day ago(with another question, to be honest), but I've got no answer.
You know, I found a "sqlite3.dll" file, but I fear it's not enough - I'd should add something which allows comunication between lua and sqlite, shouldn't I? :P Before asking to official lua forums (where I am not sure they know about this old plugin) I wanted to ask here, I'll be waiting some time. :)
#3
Hi,
sorry for writing in this old topic, but I have a problem with this plugin.
I have installed it correctly and it works fine with simple lua scripts. But now, in order to write my real code, I need another lua module (luasql.sqlite, exactly).
In this case, what should I do? I am not expert about how Lua Works and I haven't found any dll for that module; and If I am not wrong the modules I got must be installed directly into lua.

Can you give me any hint?

Thanks.
#4
Thanks for answering. I guess I'm going to use SqlLite with the lua plugin (I don't want an online database) and asking Calin for giving me some hint about how to use that properly.

Thanks again.
#5
Hi,

I am currently writing a sport manager with AGS (thst's odd, I know). Now, since I am thinking to include quite a big number of teams, I'd like to include all data in a separate database. In fact I am a bit worried about some tables, like the one reserved for players and the one for their names/surnames, since they would store some thousand of records. I know the basics about SQL, but I can't figure how to manage it with AGS, since I'd like to read and write data from a database. Using text files and their functions inside AGS wouldn't probably be appropriate (loop 2-3000 rows of text every time to find data of a player?), and I don't know how much is "safe" to build very long structs with 2000+ elements.

So... How could I make it? I didn't find any plugin about that, and I couldn't get any help from the previous topics about the subject.

#6
Hi to all,
I'm feeling a bit ashamed, while publishing my humble project among all these great games, anyways...


Here it is. As you've read in the title, I'm trying to make a sort of board game inspired to masterpieces like Final Fantasy Tactics. My game is based on an anime called "Higurashi no Naku Noro ni", and the various pieces are indeed characters of that saga.

Now, let me explain the rules of the game at once:












1There are two parties, the Yamainu (red pawns) and the Club (blue pawns). The Yamainu's purpose is to kill Rika Furude, the blue-haired girl, by the end of the turns. Preventing them from doing so is instead the task of the other team.
2Each pawn carries his own values about attack, defense and life points. The system is quite simple and intuitive, once seen in the game it should be clear enough. Actually all the pawns in the demo have random values, but they all can be modified thanks to the editor present in the options.
3Each turn is made of two phases. The first one is the movement of a piece, the second can be another movement, an attack, the healing of a piece, or a special move.
4The board is divided in five zones, wood, dump (yes, a dump), shrine, village and a luxurious manor. The various pieces may have a favorite zone where they can boost their attack and defense. By right-clicking on the various pieces you can have a brief description of them.
5When someone attacks, if the one attacked has some other enemy next to him he gets further damages; if he has some ally next to him, instead, he increases his defense.
6From time to time, on the board some object appears. As you can easily imagine, they can give you several boosts.
7If a pawn is killed and removed from play, the police ("Oishi") may appear on that zone of the board. If so, if someone attacks in that same zone he's arrested and removed in turn, unless he finds a way to get rid of the detective instantly.
8From time to time, "The Syndrome" can arrive and grab someone's brain. If you don't know about the anime, you just have to know that in this case the pawn go crazy and is not controlled by the player anymore (indeed the pawn itself becomes gray). It attacks anyone next to him, and he can be healed only by the Doctor ("Irie"), a neutral piece who appears in this case and who never attacks. Still, the medic has low values of attack, defense and life points and he can be easily attacked and killed, if the player wants to. Moreover, both the doctor and the police can be driven crazy, too.
9Each piece has his own special power, which can mostly be used once during each match.
10In the very first turns, nobody can attack nor use special moves. Since the pawns are put randomly in the beginning of the game, the first turns are used to move them in order to follow the player's strategy. When the Watanagashi starts, players will be allowed to attack too.
11There are a bunch of other sub-rules, but these are the basics, I hope the result will be enjoyable. :)



and here's a screenshot (I should consider this like an one-room game, correct?)

This is the list of what I've done and what I haven't yet:
FEATURES: The rules of the game above have all been implemented, but I still have to add a decent AI. We could say the two players mode is almost ready and the one player mode isn't. The AI will set the difficulty of the game, but not only, since there's already a complete section of options where you can edit most of the elements of the game, as well as the strength of the pieces. Of course, I will consider adding any special power, object and rule you're going to submit.
GRAPHICS: The GUI is substantially ready, thanks to the well-known GIMP. But about the pictures of the characters-pawns... Well... my dream would be finding someone able to draw original pictures (for free, whoops!), but we will see. Also adding other graphical effects and animation is on the ToDo list, it will depend also on the time I will be able to dedicate to it.
AUDIO: I'm availing of http://dig.ccmixter.org/ and http://www.freesound.org/ to get songs and sound effects. I'm planning to add more effects in the future.
PUZZLES: Puzzles?  ???

Well... that's it. The game is actually in English and Italian (guess where I am from? :p). Let me know if you find this game interesting :smiley:
SMF spam blocked by CleanTalk