Raised This Month: $ Target: $400
 0% 

Connect Separate Plugins?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Mirun.Frontier
Member
Join Date: Aug 2008
Old 04-28-2011 , 01:35   Re: Connect Separate Plugins?
Reply With Quote #7

thanks Emp, I didn't really take a look at that thread nor found it in the first page of a search.

Ok I tried to follow that, but the plugin still doesn't load.

PHP Code:
public plugin_natives()
{
    
register_library("bazookamod")
    
    
register_native("give_item_bazooka","give_item_bazooka")

The native registered in the bazooka adv plugin.

PHP Code:
public give_item_bazooka(id,ammo,sound) {
    
give_item(id"weapon_c4"// give actual weapon
    
hasBazooka[id] = true // the plugin now knows they have a bazooka
    
Munni[id] = ammo //set ammunition
    
CanShoot[id] = true // they can shoot now
    
cs_set_user_plant(id,0,0//they can't plant unless they switch to bomb
    
mode[id] = //mode = normal
    
modetext[id] = 1
    check_model
(id// refresh model
    
ammo_hud(id0)
    
ammo_hud(id1// refresh hud info
    
if (sound) {
        
//audio notification
        
emit_sound(idCHAN_ITEM"items/gunpickup2.wav"VOL_NORMATTN_NORM0PITCH_NORM)
    }

this is the function that give the bazooka.

PHP Code:
// Advanced Bazooka Include File //
#if defined _bazookamod_included
  #endinput
#endif
#define _bazookamod_included

#pragma reqlib "dyn_test"


native give_item_bazooka(id,ammo,sound
and this is the include file im using (It is included in the shop plugin)
@Bugsy, its a function within Bazooka Advanced.
__________________
I can't believe I wasted 5 years of my life not knowing how to program correctly. Went too deep into advanced coding before even learning the basics correctly. :c

Last edited by Mirun.Frontier; 04-28-2011 at 19:28.
Mirun.Frontier is offline
 



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 19:47.


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