tables within tables using lube lube.bin: pack/unpack

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
silver_hawk
Prole
Posts: 36
Joined: Mon Feb 27, 2012 2:19 pm

tables within tables using lube lube.bin: pack/unpack

Post by silver_hawk »

I'm trying to send tables within tables with lube, and I tried using different seperators and same seperators, but none of it seems to work, anyone got experience doing this stuff? I really want to send tables within tables.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: tables within tables using lube lube.bin: pack/unpack

Post by Robin »

What is your code?
Help us help you: attach a .love.
User avatar
trubblegum
Party member
Posts: 192
Joined: Wed Feb 22, 2012 10:40 pm

Re: tables within tables using lube lube.bin: pack/unpack

Post by trubblegum »

You just need a decent JSON lib.
User avatar
kikito
Inner party member
Posts: 3153
Joined: Sat Oct 03, 2009 5:22 pm
Location: Madrid, Spain
Contact:

Re: tables within tables using lube lube.bin: pack/unpack

Post by kikito »

There is TSerial. Or this thread about table serialization in the Lua Users wiki.
When I write def I mean function.
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: tables within tables using lube lube.bin: pack/unpack

Post by bartbes »

There's a reason lube.bin is no more.
meoiswa
Prole
Posts: 48
Joined: Wed Mar 14, 2012 8:13 pm
Location: Venezuela

Re: tables within tables using lube lube.bin: pack/unpack

Post by meoiswa »

Attachments
Serialize.love
Contains serialize.lua and a little main.lua showing how to use it :)
(2.22 KiB) Downloaded 57 times
Write the ö of Löve with Alt+numPad(148) or Alt+numPad(153)
User avatar
silver_hawk
Prole
Posts: 36
Joined: Mon Feb 27, 2012 2:19 pm

Re: tables within tables using lube lube.bin: pack/unpack

Post by silver_hawk »

Ty all of you I will try to read on some of the links, otherwise I will provide my code :D but maybe I could learn something usefull ;)
User avatar
silver_hawk
Prole
Posts: 36
Joined: Mon Feb 27, 2012 2:19 pm

Re: tables within tables using lube lube.bin: pack/unpack

Post by silver_hawk »

bartbes wrote:There's a reason lube.bin is no more.
lube.bin is no more? I got an old version of lube or something?
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: tables within tables using lube lube.bin: pack/unpack

Post by bartbes »

You must have, check out the repo.
User avatar
silver_hawk
Prole
Posts: 36
Joined: Mon Feb 27, 2012 2:19 pm

Re: tables within tables using lube lube.bin: pack/unpack

Post by silver_hawk »

TSerial did the trick very easy and effectively, everything is working fine now (except for the game ofc. but that is my fault), but packages are sent packed/unpacked properly now, ty for your time :)
Post Reply

Who is online

Users browsing this forum: No registered users and 176 guests