Closed Se8870 closed 2 years ago
@ADRFranklin
Thanks for this, a useful addition and some welcome improvements to the code! I just had one question regarding the default path of
../
for filterscripts that's all
Thanks for reviewing this, for ../
path let me explain.
The reason why ../
is because when you creating the filterscript, the contents should be in:
| -- server_root
| -- Filterscript
| -- my-system
So, doing ../
would place the .amx
outside the folder name.
If i could make the path like this filterscripts/
, then it should search the "server_files" not just "filterscript/my-system" folder.
Unfortunately this is out of my reach :sweat_smile:
Could you please use absolute paths instead of relative paths. There are already code variables available in that code section that have absolute paths to the current working directory.
Could you please use absolute paths instead of relative paths. There are already code variables available in that code section that have absolute paths to the current working directory.
Yes, but when i tried to build it it creates the absolute path
inside the server folder
sampctl/test 🍣 dev 📝 ×1🛤️ ×1
🕙 07:27:48 ❯ tree
.
├── announce
├── dependencies
│ ├── pawn-stdlib
│ └── samp-stdlib
├── filterscripts
├── gamemodes
├── home
│ └── yuusha
│ └── Documents
│ └── go-project
│ └── sampctl
│ └── test
│ └── gamemodes
│ └── test.amx
├── pawn.json
├── README.md
├── samp03svr
├── samp-npc
├── server.cfg
└── test.pwn
Then however you have decided to write it is not correct. You can easily make this work, by using the correct utilities.
Then however you have decided to write it is not correct. You can easily make this work, by using the correct utilities.
Let me see what i can do with that... I mean, i can tweak some of its settings and make it working tbh.
Could you please use absolute paths instead of relative paths. There are already code variables available in that code section that have absolute paths to the current working directory.
This is wrong, you can't use absolute paths, it must be relative from the CWD. The question was more about why it was the parent, this may be confusing if the user runs sampctl from the root but that's likely less common than running it from within filterscripts.
This makes sense though, thanks @Se8870 I forgot about the extra directory within the filterscripts
directory tree.
@Southclaws What do you mean you can't use absolute paths?
Could you please use absolute paths instead of relative paths. There are already code variables available in that code section that have absolute paths to the current working directory.
This is wrong, you can't use absolute paths, it must be relative from the CWD. The question was more about why it was the parent, this may be confusing if the user runs sampctl from the root but that's likely less common than running it from within filterscripts.
This makes sense though, thanks @Se8870 I forgot about the extra directory within the
filterscripts
directory tree.
you welcome 😁
so, about the absolute path, should i revert it and use "../" instead?
It seems like i've been staling for quite a time. I'll close this commit and make another one if i can figure it out how to do stuff because tbh i'm just new to this one.
Plus i can't fetch dev repo.
The reason why i've make this PR because currently sampctl only support for gamemode (both gamemode and library type).
This brings new type to ensure the output path to
../
for filterscript andgamemodes/
for both gamemode and libraries since creating new filterscript would require you to also have the same folder name as your fs.You can also just revert adding
gamemodes/
foroutput
inpawn.json
and close this PR and i'll make another pr about just removing "package" in generated pwn code.