Raised This Month: $ Target: $400
 0% 

Solved Add character in existing line


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 08-14-2018 , 06:53   Re: Add character in existing line
Reply With Quote #1

Quote:
Originally Posted by edon1337 View Post
I'm aware of that already, but isn't there another way?
No, that's how files work, they are streams, it's not AMXX's thing.
__________________

Last edited by klippy; 08-14-2018 at 06:53.
klippy is offline
edon1337
Penguin Enthusiast
Join Date: Jun 2016
Location: Macedonia
Old 08-14-2018 , 06:54   Re: Add character in existing line
Reply With Quote #2

Quote:
Originally Posted by KliPPy View Post
No, that's how files work, they are streams, it's not AMXX's thing.
Delete the line and write a new one at it's place?
__________________
edon1337 is offline
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 08-14-2018 , 06:58   Re: Add character in existing line
Reply With Quote #3

Quote:
Originally Posted by edon1337 View Post
Delete the line and write a new one at it's place?
It doesn't work that way. It will only work provided the the new and old lines have the same length. As I said, files are streams, they can only be appended to or overwritten, you can't insert in the middle or delete content.
__________________

Last edited by klippy; 08-14-2018 at 07:01.
klippy is offline
edon1337
Penguin Enthusiast
Join Date: Jun 2016
Location: Macedonia
Old 08-14-2018 , 07:03   Re: Add character in existing line
Reply With Quote #4

Quote:
Originally Posted by KliPPy View Post
It doesn't work that way. It will only work provided the the new and old lines have the same length. As I said, files are streams, they can only be appended to or overwritten, you can't insert in the middle or delete content.
Ah, I see. I'll use this then, thanks https://forums.alliedmods.net/showpo...56&postcount=5
__________________
edon1337 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 12:45.


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