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

Problem with compile


Post New Thread Reply   
 
Thread Tools Display Modes
Sale
Junior Member
Join Date: Aug 2011
Old 05-03-2012 , 09:26   Re: Problem with compile
Reply With Quote #11

i know to compile a plugin, just like i said in second post, when i try to compile sma without my edit, i get it compiled
__________________

Najbolji hosting u Srbiji, Tesla Hosting www.tesla-host.webs.com

Last edited by Sale; 05-03-2012 at 09:26.
Sale is offline
wickedd
Veteran Member
Join Date: Nov 2009
Old 05-03-2012 , 09:35   Re: Problem with compile
Reply With Quote #12

Quote:
Originally Posted by Sale View Post
I was edited this plugin, using aaarnas tutorial > here
When try compile i got this error :


This is my (edited) code:
PHP Code:
/*
    ----------------------------
    Description
    ----------------------------
    A Zombie Class for Zombie Plague Mod( Dummy Zombie )
    What can this do?
    
    * Liez to them and backstab them :D
    * Trap them
    
    ----------------------------
    Update Logs
    ----------------------------
    v1.0 - Intial Release
    
    ----------------------------
    Suggestions & Bug reporting
    ----------------------------
    1. PM( Private Message ) me( Recommended, I online very often. )
    
    ----------------------------
    Credits
    ----------------------------
    007 -> Re-edited it to a zombie :|
    Twilight Suzuka -> NPC Plug-in( https://forums.alliedmods.net/showthread.php?t=11756 )
    01101101 -> Removing entity on Round Start( https://forums.alliedmods.net/showpost.php?p=1071507&postcount=3 )
    ----------------------------
*/

#include < amxmodx >
#include < engine >
#include < zombieplague >

new const zclass_name[ ] = "Illusion Zombie"
new const zclass_info[ ] = "Make Dummy [E]"
new const zclass_model[ ] = "za_fleshpound"
new const zclass_clawmodel[ ] = "v_knife_zombie_fleshpound.mdl"
const zclass_health 2000
const zclass_speed 200
const Float:zclass_gravity 1.0
const Float:zclass_knockback 0.5

// Models
new const dummy_model[ ] = "models/player/za_fleshpound/za_fleshpound.mdl"

new g_zclass_dummygCvarDummyShouldDiegCvarDummyHealthgCvarDummyAnimationgCvarDummyLimit

// Prevents people from spamming
new gCounter33 ]

public 
plugin_init( ) 
{
    
register_plugin"[ZP] Zombie Class: Dummy Zombie""1.0""007 & Twilight Suzuka & 01101101" )
    
    
register_think"npc_dummy","npc_think" )
    
    
register_event"HLTV""event_new_round""a""1=0""2=0" )
    
    
gCvarDummyShouldDie register_cvar"zp_dummy_should_die""1" // ( 0 : Dummy will not die || 1: Dummy will die ) Default: 1
    
gCvarDummyHealth register_cvar"zp_dummy_health""100" // Dummy's health Default: 100
    
gCvarDummyAnimation register_cvar"zp_dummy_animation""1" // ( 0 : Dummy floating animation || 1: Dummy standing animation ) Default: 1
    
gCvarDummyLimit register_cvar"zp_dummy_spawn_limit""5" // Amount of dummy he can spawn when he gets infected
    // NOTE: If he antidotes and get infected again he can spawn dummies again.
}

public 
plugin_precache( )
{
    
g_zclass_dummy zp_register_zombie_classzclass_namezclass_infozclass_modelzclass_clawmodelzclass_healthzclass_speedzclass_gravityzclass_knockback )
    
precache_modeldummy_model )
}
public 
zp_user_infected_pre(id) {
    if(!(
get_user_flags(id) & ADMIN_LEVEL_C)) {
        if (
zp_get_user_next_class(id) == g_zclass_dummy) {
            
zp_set_user_zombie_class(id0)
            
client_print(idprint_center"Klasa koju si odabrao je samo za *HEAD* Admine.")
            
client_print(idprint_chat"Odabrana klasa je samo za *HEAD* Admine. Bice promenjena na The Undead.")
        }    
    }
}  
// Thanks 01101101( Removing entity )
public event_new_round( )
{
    new 
ent = -1
    
while( ( ent find_ent_by_classent"npc_dummy" ) ) )
    {
        
remove_entityent )
    }
}

public 
client_PreThinkid )
{
    if( !
is_user_aliveid ) || !zp_get_user_zombieid ) || zp_get_user_zombie_classid ) != g_zclass_dummy || zp_get_user_nemesisid ) || zp_get_user_survivorid ) )
        return 
PLUGIN_HANDLED
    
    
// No more slowhacking!
    
new button get_user_buttonid )
    new 
oldbutton get_user_oldbuttonid )
    
    if( !( 
oldbutton IN_USE ) && ( button IN_USE ) )
        
create_dummyid )

    return 
PLUGIN_HANDLED
}

public 
zp_user_infected_postidinfector )
{
    if( 
zp_get_user_zombie_classid ) == g_zclass_dummy && !zp_get_user_nemesisid ) )
    {
        
gCounterid ] = 0
        client_print
idprint_chat"[ZP] Press your ^"+use^" button to build a dummy!" )
    }
}

public 
create_dummyid )
{
    if( 
gCounterid ] >= get_pcvar_numgCvarDummyLimit ) )
    {
        
client_printidprint_chat"[ZP] Достигнут лимит илюзии!" )
        return 
PLUGIN_HANDLED
    
}
    
    new 
Float:origin]
    
    
entity_get_vectoridEV_VEC_origin,origin )
    
    new 
ent create_entity"info_target" )
    
    
entity_set_originentorigin )
    
origin] += 50.0
    entity_set_origin
id,origin )
    
    
entity_set_floatentEV_FL_takedamageget_pcvar_floatgCvarDummyShouldDie ) )
    
entity_set_floatentEV_FL_healthget_pcvar_floatgCvarDummyHealth ) )
    
    
entity_set_stringentEV_SZ_classname"npc_dummy" )
    
entity_set_modelentdummy_model )
    
entity_set_intentEV_INT_solid)
    
    
entity_set_byteentEV_BYTE_controller1125 )
    
entity_set_byteentEV_BYTE_controller2125 )
    
entity_set_byteentEV_BYTE_controller3125 )
    
entity_set_byteentEV_BYTE_controller4125 )
    
    new 
Float:maxs] = { 16.016.036.0 }
    new 
Float:mins] = { -16.0, -16.0, -36.0 }
    
    
entity_set_sizeentminsmaxs )
    
    
entity_set_floatentEV_FL_animtime2.0 )
    
entity_set_floatentEV_FL_framerate1.0 )
    
entity_set_intentEV_INT_sequenceget_pcvar_numgCvarDummyAnimation ) )
    
    
entity_set_floatent,EV_FL_nextthinkhalflife_time( ) + 0.01 )
    
    
drop_to_floorent )
    
    
gCounterid ] ++
    
client_printidprint_chat"[ZP] You've used %d / %d dummies."gCounterid ], get_pcvar_numgCvarDummyLimit ) )
    
    return 
1
}

public 
npc_thinkid )
{
    
entity_set_floatidEV_FL_nextthinkhalflife_time( ) + 0.01 )
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/ 
Please help
The code compiles.
__________________
Just buy the fucking game!!!!
I hate No-Steamers and lazy ass people.
wickedd is offline
Bilal Pro
Senior Member
Join Date: Mar 2012
Location: Holland
Old 05-03-2012 , 09:37   Re: Problem with compile
Reply With Quote #13

Also for me
__________________
  • Point System with rank titles for sale [X] [100% private]
  • VIP Menu for sale [X] [100% private]
  • HnS shop more features for sale [X] [100% private]
Contact: Bilalzaandam1234, on steam if you are interested.
Bilal Pro is offline
Sale
Junior Member
Join Date: Aug 2011
Old 05-03-2012 , 10:11   Re: Problem with compile
Reply With Quote #14

Can i give u a sma to compile for me?
__________________

Najbolji hosting u Srbiji, Tesla Hosting www.tesla-host.webs.com

Last edited by Sale; 05-03-2012 at 10:12.
Sale is offline
wickedd
Veteran Member
Join Date: Nov 2009
Old 05-03-2012 , 10:22   Re: Problem with compile
Reply With Quote #15

The .sma of what, the code you posted above?
__________________
Just buy the fucking game!!!!
I hate No-Steamers and lazy ass people.
wickedd is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-03-2012 , 10:28   Re: Problem with compile
Reply With Quote #16

open some sma files what compiles copy and paste it and rename it.
Copy the code what you posted here and paste it to copied sma file.
Then compile and see it will work

also if you know how to rename file tag then just create new txt document and rename .txt to .sma and then paste code inside of it.
.Dare Devil. is offline
Sale
Junior Member
Join Date: Aug 2011
Old 05-03-2012 , 10:51   Re: Problem with compile
Reply With Quote #17

Quote:
Originally Posted by .Dare Devil. View Post
open some sma files what compiles copy and paste it and rename it.
Copy the code what you posted here and paste it to copied sma file.
Then compile and see it will work

also if you know how to rename file tag then just create new txt document and rename .txt to .sma and then paste code inside of it.
I already do all that

EDIT:
Quote:
Originally Posted by wickedd View Post
The .sma of what, the code you posted above?
Yes that code above.
__________________

Najbolji hosting u Srbiji, Tesla Hosting www.tesla-host.webs.com

Last edited by Sale; 05-03-2012 at 10:52.
Sale is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-03-2012 , 10:58   Re: Problem with compile
Reply With Quote #18

Quote:
Originally Posted by Sale View Post
I already do all that
Omg
Your sma format is UTF-8 but it must be UTF-8 without BOM
so you did not do that what i said.
.Dare Devil. is offline
Sale
Junior Member
Join Date: Aug 2011
Old 05-03-2012 , 11:00   Re: Problem with compile
Reply With Quote #19

Quote:
Originally Posted by .Dare Devil. View Post
Omg
Your sma format is UTF-8 but it must be UTF-8 without BOM
so you did not do that what i said.
No, my sma is UTF-8 without BOM

EDIT: Sry, i change format to ANSI, and now works
EDIT 2: Thank you all
__________________

Najbolji hosting u Srbiji, Tesla Hosting www.tesla-host.webs.com

Last edited by Sale; 05-03-2012 at 11:06.
Sale is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-03-2012 , 11:08   Re: Problem with compile
Reply With Quote #20

Quote:
Originally Posted by Sale View Post
No, my sma is UTF-8 without BOM

EDIT: Sry, i change format to ANSI, and now works
if it UTF-8 without BOM then there will come any extra letter in line 1
and then there will not be that error, you using notepad or notepad++ ?
.Dare Devil. is offline
Old 05-03-2012, 11:08
wickedd
This message has been deleted by wickedd. Reason: problem solved
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 18:52.


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