User Tools

Site Tools


lua:savetbl

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
lua:savetbl [2014/12/24 05:31]
vodur created
— (current)
Line 1: Line 1:
-====savetbl==== 
-Syntax: savetbl( filename, table) 
  
-Saves '​table'​ in a file named according to '​filename'​ arg in the area directory (home area, not current area) of the mob/​obj/​area calling savetbl. ​ 
- 
-Example: 
-<code lua> 
-local abc={1,2,3} 
-savetbl("​whatev",​ abc) 
-</​code>​ 
- 
-====loadtbl==== 
-Syntax: loadtbl( filename ) 
- 
-If '​filename'​ file exists in the area directroy of the mob/​obj/​area calling loadtbl then returns the table stored in it, otherwise returns nil. 
-Example: 
-<code lua> 
-local oink=loadtbl("​whatev"​) 
-</​code>​ 
- 
- 
-Example script: 
-[[:​lua:​examples:​sharinginfo|Sharing Info Between Progs]] 
lua/savetbl.1419399114.txt.gz ยท Last modified: 2014/12/24 05:31 by vodur