Raised This Month: $ Target: $400
 0% 

Cant Compile


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
4iriks
Member
Join Date: Nov 2009
Old 05-12-2010 , 12:01   Cant Compile
Reply With Quote #1

So , i downloaded the extra item plugin for ZP , and i wanted to do some changes , BUT , when im trying to compile , it shows me this -

Code:
/home/groups/amxmodx/tmp3/php3vr2Uy.sma(23) : fatal error 100: cannot read from file: "zombieplague.inc"

Compilation aborted.
1 Error.
The Code is -

Code:
/*================================================================================
	
	-------------------------------------------
	-*- [ZP] Extra Item: Multijump 1.0 -*-
	-------------------------------------------
	
	~~~~~~~~~~~~~~~
	- Description -
	~~~~~~~~~~~~~~~
	
	This item/upgrade allows humans to jump multiple times, even being in mid air.
	Each upgrade adds one jump.
	
	By default there is no maximum of jumps in mid air.
	
	Credits to:
	twistedeuphoria
	Dabbi
================================================================================*/

#include <amxmodx>
#include <fakemeta>
#include <zombieplague.inc>

/*================================================================================
 [Plugin Customization]
=================================================================================*/

new const g_item_name[] = { "Multijump (+1)" };
const g_item_cost = 8;
new g_maxJumps = 5; // maximum amount of jumps in mid air. If set to 0 then it is infinitely

/*============================================================================*/

new jumpnum[33] = 0;
new bool:dojump[33] = false;
new g_itemid_multijump;
new g_multijumps[33] = 0;

public plugin_init()
{
	register_plugin("[ZP] Extra Item: Multijump", "1.0", "pharse");
	
	g_itemid_multijump = zp_register_extra_item(g_item_name, g_item_cost, ZP_TEAM_HUMAN);
	
	register_forward(FM_PlayerPreThink, "FW_PlayerPreThink");
	register_forward(FM_PlayerPostThink, "FW_PlayerPostThink");
	
	register_event("HLTV", "EVENT_round_start", "a", "1=0", "2=0");
}

public FW_PlayerPreThink(id)
{
	if(!is_user_alive(id) || zp_get_user_zombie(id) || !g_multijumps[id]) return PLUGIN_CONTINUE
	new nbut = pev(id,pev_button);
	new obut = pev(id,pev_oldbuttons);
	if((nbut & IN_JUMP) && !(pev(id,pev_flags) & FL_ONGROUND) && !(obut & IN_JUMP))
	{
		if(jumpnum[id] < g_multijumps[id])
		{
			dojump[id] = true;
			jumpnum[id]++;
			return PLUGIN_CONTINUE
		}
	}
	if((nbut & IN_JUMP) && (pev(id,pev_flags) & FL_ONGROUND))
	{
		jumpnum[id] = 0;
		return PLUGIN_CONTINUE
	}
	return PLUGIN_CONTINUE
}

public FW_PlayerPostThink(id)
{
	if(!is_user_alive(id) || zp_get_user_zombie(id) || !g_multijumps[id]) return PLUGIN_CONTINUE
	if(dojump[id] == true)
	{
		new Float:velocity[3];
		pev(id,pev_velocity,velocity);
		velocity[2] = random_float(265.0,285.0);
		set_pev(id,pev_velocity,velocity)
		dojump[id] = false
		return PLUGIN_CONTINUE
	}
	return PLUGIN_CONTINUE
}	

// Player buys our upgrade, add one multijump
public zp_extra_item_selected(player, itemid)
{
	if (itemid == g_itemid_multijump){
		if (g_multijumps[player] < g_maxJumps || !g_maxJumps){
			g_multijumps[player]++;
			if (g_maxJumps)
				client_print(player, print_center, "Now you can jump %d / %d times in mid air.", g_multijumps[player], g_maxJumps);
			else
				client_print(player, print_center, "Now you can jump %d times in mid air.", g_multijumps[player]);
		}
		else
			client_print(player, print_center, "You can't jump more than %d times in mid air!", g_maxJumps);
	}
}

// Reset multijump for all players on newround
public EVENT_round_start()
{
	for (new id; id <= 32; id++) g_multijumps[id] = true;
}

Question - How i can compile it?
4iriks is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 05-12-2010 , 12:03   Re: Cant Compile
Reply With Quote #2

You need to compile it locally
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
FlyingHorse
Senior Member
Join Date: Apr 2010
Location: Under your bed.
Old 05-12-2010 , 12:11   Re: Cant Compile
Reply With Quote #3

You cannot use the web compiler if there is a custom include in the plugin. the web compiler only have the standards
FlyingHorse is offline
Send a message via Skype™ to FlyingHorse
4iriks
Member
Join Date: Nov 2009
Old 05-12-2010 , 15:12   Re: Cant Compile
Reply With Quote #4

Where i can download some good compiler?

and then where i must put that zombieplague.inc file?
4iriks is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 05-12-2010 , 15:45   Re: Cant Compile
Reply With Quote #5

Quote:
Originally Posted by 4iriks View Post
Where i can download some good compiler?

and then where i must put that zombieplague.inc file?
you got a compiler in amxmodx/scripting and the inc. goes in amxmodx/scripting/include
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
infek
Senior Member
Join Date: May 2009
Location: Behind you
Old 05-17-2010 , 19:19   Re: Cant Compile
Reply With Quote #6

zombieplague.inc
isnt it suppose to just be <zombieplague>
__________________
"Domo Arigato, Mr. Roboto!"
PM me if you want to know a secret
infek is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 05-17-2010 , 19:35   Re: Cant Compile
Reply With Quote #7

Quote:
Originally Posted by infek View Post
zombieplague.inc
isnt it suppose to just be <zombieplague>
It should work either way if the include file exists.
__________________
fysiks 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 03:39.


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