Raised This Month: $12 Target: $400
 3% 

[CS:GO/ZP] Zombie Plague Mod 8.3.2


Post New Thread Reply   
 
Thread Tools Display Modes
Franc1sco
Veteran Member
Join Date: Oct 2010
Location: Spain (Madrid)
Old 10-04-2015 , 21:30   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #21

Quote:
Originally Posted by gubka View Post
I didn't find anything look like a nvault.inc from cs 1.6 which saving data in file in folder of server
Use keyvalues: https://sm.alliedmods.net/new-api/keyvalues

I used it for save info in a file in the server in plugins like my gangs mod
__________________
Veteran Coder -> Activity channel
Coding on CS2 and taking paid and free jobs.

Contact: Steam, Telegram or discord ( franug ).

You like my work? +Rep in my steam profile comments or donate.

Franc1sco is offline
Send a message via MSN to Franc1sco
gubka
Veteran Member
Join Date: Jan 2012
Location: Russia
Old 10-05-2015 , 04:25   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #22

Quote:
Originally Posted by Franc1sco View Post
Use keyvalues: https://sm.alliedmods.net/new-api/keyvalues

I used it for save info in a file in the server in plugins like my gangs mod
Thanks man , today I will add ammopack saving
__________________
gubka is offline
Send a message via ICQ to gubka
gubka
Veteran Member
Join Date: Jan 2012
Location: Russia
Old 10-05-2015 , 09:47   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #23

I do level system like that , HUD in cso


Each level increased damage
__________________

Last edited by gubka; 10-05-2015 at 09:47.
gubka is offline
Send a message via ICQ to gubka
Lannister
Veteran Member
Join Date: Apr 2015
Old 10-05-2015 , 13:14   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #24

Very excited about this, keep up the good work!
Lannister is offline
gubka
Veteran Member
Join Date: Jan 2012
Location: Russia
Old 10-05-2015 , 17:09   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #25

Quote:
Originally Posted by Lannister View Post
Very excited about this, keep up the good work!
I am fineshed saving ammo pack, when i will fineshed lvl and buysystem , i will update link here, wait during week

Code:
//**********************************************
//* DataBase Staff.                 		   *
//**********************************************

void Create_DataBase()
{
	if (DataBase != INVALID_HANDLE)
		CloseHandle(DataBase);

	Format(DataBaseFile, PLATFORM_MAX_PATH, "addons/sourcemod/%s", KV_DATABASE_NAME);
	
	if(!FileExists(DataBaseFile))
	{
		char DataBasePath[PLATFORM_MAX_PATH];
		BuildPath(Path_SM, DataBasePath, sizeof(DataBasePath), KV_DATABASE_NAME);
	
		DataBase = CreateKeyValues(KV_DATABASE_KEY);
		KeyValuesToFile(DataBase, DataBasePath);
		
		PrintToServer("[ZBM3_DATABASE] Database was created!");
	}
	else 
	{
		DataBase = CreateKeyValues(KV_DATABASE_KEY);
		FileToKeyValues(DataBase, DataBaseFile);
		
		PrintToServer("[ZBM3_DATABASE] Database was upload from server folder!");
	}
}

public int Check_DataBase(int iPlayer)
{
	Format(DataBaseFile, PLATFORM_MAX_PATH, "addons/sourcemod/%s", KV_DATABASE_NAME);

	if(!FileExists(DataBaseFile))
	{
		PrintToServer("[ZBM3_DATABASE] ERROR: file not exist");
		return 0;
	}
    else if (KvJumpToKey(DataBase, pSteamID[iPlayer], false)) 
    { 
		int pAmmoCount; 
		pAmmoCount = KvGetNum(DataBase, KV_DATABASE_STRING); 

		KvDeleteThis(DataBase); 
		KvRewind(DataBase); 
		KeyValuesToFile(DataBase, DataBaseFile);
	   
		PrintToServer("[ZBM3_DATABASE] Ammo was loaded for: %s, Found: %i ammopacks", pSteamID[iPlayer], pAmmoCount);
	   
		return pAmmoCount;
    } 
    else 
	{
		PrintToServer("[ZBM3_DATABASE] Ammo for New Player will create after disconnect: %s", pSteamID[iPlayer]);
		
		return AMMOPACK_FOR_NEW_PLAYER;
	}
}

void Save_DataBase(int iPlayer, int iPlayer_Ammo)
{
	Format(DataBaseFile, PLATFORM_MAX_PATH, "addons/sourcemod/%s", KV_DATABASE_NAME);

	if(!FileExists(DataBaseFile))
	{
		PrintToServer("[ZBM3_DATABASE] ERROR: file not exist");
		return;
	}
	
	// And create new one
	KvJumpToKey(DataBase, pSteamID[iPlayer], true); 
	KvSetNum(DataBase, KV_DATABASE_STRING, iPlayer_Ammo); 
	KvRewind(DataBase); 
	KeyValuesToFile(DataBase, DataBaseFile); 
	
	PrintToServer("[ZBM3_DATABASE] Ammo was saved for: %s with: %i ammopacks", pSteamID[iPlayer], iPlayer_Ammo);
}
__________________
gubka is offline
Send a message via ICQ to gubka
gubka
Veteran Member
Join Date: Jan 2012
Location: Russia
Old 10-05-2015 , 21:14   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #26

Tomorrow I Will start create overlays , I did level system today, therefore I will start create buy system menu , which will using key value to upload prices and which weapon to able
__________________
gubka is offline
Send a message via ICQ to gubka
Lannister
Veteran Member
Join Date: Apr 2015
Old 10-05-2015 , 22:27   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #27

Seems like you're doing a great work there man! lets hope this thread gets more attention since this seems like it will be a great plugin!
Lannister is offline
veli
Senior Member
Join Date: Apr 2012
Location: Netherlands
Old 10-06-2015 , 00:32   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #28

Gubka, are you coldfir3 ? Lol this idea is very cool if you can complete it.
veli is offline
veli
Senior Member
Join Date: Apr 2012
Location: Netherlands
Old 10-06-2015 , 00:43   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #29

lol i joined the test server but it seems not oke? counting sound going very fast, and when human turn in to zombie than round end restart immediatly.
veli is offline
gubka
Veteran Member
Join Date: Jan 2012
Location: Russia
Old 10-06-2015 , 04:37   Re: [CS:GO] Zombie Plague Mod 3 (4.10.2015)
Reply With Quote #30

I have problem with // Main timer for Zombie Mod start
CreateTimer(1.0, EventMakeZombie, _, TIMER_REPEAT);
I don't know reason
__________________
gubka is offline
Send a message via ICQ to gubka
Reply


Thread Tools
Display Modes

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 15:55.


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