Read files not from server dir
I have my server in "C:\HLserver" dir.
Is it possible to read text from file "C:\lol.txt" ?? Or it's possible only if file is in server dir? + karma for answer |
Re: Read files not from server dir
Because here http://www.amxmodx.org/doc/index.htm...Fread_file.htm does not specify this matter i think that it is possible.You could try this by writing a little script for test to check if file C:\lol.txt exists.If it exists in this test plugin you could try to read from it and log it(to see it in console).Don't forget to add "debug"(without quotes) in plugins.ini after this test plugin.
I hope you understand my idea.As soon as I can I'll do this test on my own. |
Re: Read files not from server dir
file_exists returns 0
|
Re: Read files not from server dir
I test this and I seem not to work.I also saw that get_datadir return this path addons/amxmodx/data; so folder addons is the lowest folder accessible.
|
Re: Read files not from server dir
would "../../lol.txt" do the trick ?
|
Re: Read files not from server dir
Yes.It does the trick xPaw :). The location is actually ../../../lol.txt
1 get out of addons in cstrike 2 get out of cstrike in hlds 3 get out of hlds in partion root(c:\) |
Re: Read files not from server dir
Quote:
(I remember seeing this in like Johnny Got His Gun' first post over on the AMX Mod forum like 7 years ago saying he was using "../../../../../../../../../../../../../../../../../../" that to make sure he was going to the drives root. I remember chuckling :) And if I remember correctly, it was because the hl engine does not allow you to read other hard drives, only the drive it is installed on, so you can't use the driver letter syntax.) |
Re: Read files not from server dir
There should be no good reason to leave the mod directory.
|
| All times are GMT -4. The time now is 04:13. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.