This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

[INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!


Post New Thread Reply   
 
Thread Tools Display Modes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 07-07-2013 , 08:35   Re: [INC] SINI v1.3 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #11

As it is, it's not really recommended to use it. We should really have a section for approved tutorials.

I've nothing against you Startukk, just what you offer is wrong. Even the provided example is not a good one ; reading/writing file per player on connection is just very bad ; something you can achieve way better using nvault for example.

If you want to improve, start to use a Trie.
__________________

Last edited by Arkshine; 07-07-2013 at 08:35.
Arkshine is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-07-2013 , 13:37   Re: [INC] SINI v1.3 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #12

The description of this thread is incorrect and the examples look like you should just be using nvault. Also, SINI_ReadString returns a string, is that even possible? IIRC, you have to have to populate strings as ByRef arguments.

Arkshine, it seems that people are ignoring you (sadly). Having an approval process for tutorials is a great idea but probably won't work all that well logistically.
__________________
fysiks is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 07-07-2013 , 14:13   Re: [INC] SINI v1.3 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #13

Yes, it's possible to return a string, but depending situation, it may not that reliable, you could get stack error or something out of nowhere. At least I remember having weird issues sometimes. By reference, it's the safest way.

About approved section for tutorials, considering you don't see often new ones, I would say it should be fine.
__________________
Arkshine is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-07-2013 , 14:31   Re: [INC] SINI v1.3 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #14

Could move in scripting/help section though, as last option...
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Startukk
Junior Member
Join Date: Jul 2013
Old 07-08-2013 , 17:11   Re: [INC] SINI v1.3 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #15

I have SINI fixed and updated to version 1.4 but I cant upload it since Im at a hospital waiting for arm surgery.
SINI_ReadString has a new usage: SINI_ReadString(varname[], data, len);
New parameter "data" stores the string in a user choosed string variable, parameter "len" is the size of data string variable.
Also in 1.4 storing written variables has changed to copy(), was format() before.
I will upload the updated version as soon as I get home and get my hands on the computer.
Thanks for understanding, and have a great day.
Startukk is offline
Startukk
Junior Member
Join Date: Jul 2013
Old 07-13-2013 , 10:03   Re: [INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #16

Include is now updated to v1.4!
Check changelog
Startukk is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 07-13-2013 , 10:55   Re: [INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #17

Again, use a trie. Right now it's very very inefficient, way worse than you would do it without.

Also, review your example ; it doesn't make sense to use such stocks for that. Wrong method.

Please fix that in priority.
__________________

Last edited by Arkshine; 07-15-2013 at 09:53.
Arkshine is offline
Row
BANNED
Join Date: Jun 2013
Location: Romania
Old 07-15-2013 , 09:40   Re: [INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #18

cool
Row is offline
Startukk
Junior Member
Join Date: Jul 2013
Old 07-16-2013 , 18:13   Re: [INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #19

Quote:
Originally Posted by Row View Post
cool
Thank you very much!
Startukk is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 07-16-2013 , 18:26   Re: [INC] SINI v1.4 - Advanced File Reading/Writing - UPDATED!
Reply With Quote #20

As you seem to ignore what we said to you, moving thread in scripting section. Even though as it is, it would worth to be trashed, still giving some chance to improve things until all being fixed.
__________________
Arkshine is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:16.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode