Saving names
#1

I'm making a faction system. I made /createfaction till yet. Is there any way to save the names of factions into .ini in a folder named faction? Full explanation- Admin used /createfaction, faction got created and a new file gets created into faction folder with the name of the faction.
Reply
#2

BUMP
Reply
#3

All you really have to do is have the name saved within a string and then write a file with said string. Are you familiar with having .ini files created?
Reply
#4

You'd do this the exact same way as you would create a player's file when they register. Same principle, different file path.
Reply
#5

But that is for a player. But this one is a global type.
Reply
#6

FFS Bump! im waiting from morning i hab to complete da script
Reply
#7

Quote:
Originally Posted by Sunehildeep
Посмотреть сообщение
But that is for a player. But this one is a global type.
You realize that those "player files" are "global types" too right? The only reason you see them as "player types" is because within the script you're loading the files using the logged in player's name to locate said file. It's the same concept like the user above said.
Reply
#8

Use the same method same player files, but load them on OnGameModeInit and unload in OnGameModeExit.
Reply
#9

So I saved them as INI_WriteString but as far I know we can't load with a function like INI_String so what should I do in that case?
Reply
#10

Quote:
Originally Posted by Sunehildeep
Посмотреть сообщение
So I saved them as INI_WriteString but as far I know we can't load with a function like INI_String so what should I do in that case?
why dont?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)