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

Black Knight (srry i put the other post in wrong section)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
imported_HOMiE
Senior Member
Join Date: Feb 2005
Old 03-14-2005 , 14:27   Black Knight (srry i put the other post in wrong section)
Reply With Quote #1

the knife model doesnt show no error's but when i switch to knife there is no models

Code:
// BlackKinght! - Clan -=][F.B.I][=-'s Laser Guy with much stuff /* CVARS - copy and paste to shconfig.cfg //BlackKinght BlackKinght_level 18 BlackKinght_laser_ammo 300      //total # of shots given each round BlackKinght_laser_burndecals 1    //Show the burn decals on the walls BlackKinght_cooldown 0.0            //Cooldown timer between shots BlackKinght_mulishot 0.0            //Delay for multishots on holding key down BlackKinght_gravity 0.65            //Gravity BlackKinght_health 250        //Starting Health BlackKinght_armor 250            //Starting Armor BlackKinght_speed 800            //Running Speed */ #include <amxmod> #include <superheromod> #include <Vexd_utilities> // Damage Variables #define h1_dam 20 //head #define h2_dam 15  //body #define h3_dam 15  //stomach #define h4_dam 10  //arm #define h6_dam 10  //leg // GLOBAL VARIABLES new smoke, laser, laser_shots[SH_MAXSLOTS+1] new bool:g_hasBlackKinghtPower[SH_MAXSLOTS+1] new gLastWeapon[SH_MAXSLOTS+1] new gHeroName[]="Black Kinght" static const burn_decal[5] = {199,200,201,202,203} //---------------------------------------------------------------------------------------------- public plugin_init() {     // Plugin Info     register_plugin("SUPERHERO Black Kinght","1.17.5","AssKicR/Batman/JTP10181 & KebmasteR")     // DO NOT EDIT THIS FILE TO CHANGE CVARS, USE THE SHCONFIG.CFG     register_cvar("BlackKinght_level", "18" )     register_cvar("BlackKinght_laser_ammo", "300")  // total # of shots...     register_cvar("BlackKinght_laser_burndecals", "1")     register_cvar("BlackKinght_cooldown", "0.0" )     register_cvar("BlackKinght_mulishot", "0.0" ) //Delay for multishots on holding key down     register_cvar("BlackKinght_gravity", "0.65")     register_cvar("BlackKinght_armor", "250")     register_cvar("BlackKinght_health", "250")     register_cvar("BlackKinght_speed", "800")     register_cvar("BlackKinght_knifemult", "3.0" )     // FIRE THE EVENT TO CREATE THIS SUPERHERO!     shCreateHero(gHeroName, "hp/ap/speed/laser", "Press the +power key to fire your laser beam , get hp/ap/speed and knife dmg", true, "BlackKinght_level" )     // REGISTER EVENTS THIS HERO WILL RESPOND TO! (AND SERVER COMMANDS)     register_event("ResetHUD","newRound","b")     // KEY DOWN     register_srvcmd("BlackKinght_kd", "BlackKinght_kd")     shRegKeyDown(gHeroName, "BlackKinght_kd")     register_srvcmd("BlackKinght_ku", "BlackKinght_ku")     shRegKeyUp(gHeroName, "BlackKinght_ku")     // INIT     register_srvcmd("BlackKinght_init", "BlackKinght_init")     shRegHeroInit(gHeroName, "BlackKinght_init")     // DEATH     register_event("DeathMsg", "BlackKinght_death", "a")         // Let Server know about BlackKinghts Variable     // It is possible that another hero has more hps, less gravity, or more armor     // so rather than just setting these - let the superhero module decide each round     shSetMaxHealth(gHeroName, "BlackKinght_health" )     shSetMinGravity(gHeroName, "BlackKinght_gravity" )     shSetMaxArmor(gHeroName, "BlackKinght_armor" )     shSetMaxSpeed(gHeroName, "BlackKinght_speed", "[0]" ) } //---------------------------------------------------------------------------------------------- public plugin_precache() {     smoke = precache_model("sprites/steam1.spr")     laser = precache_model("sprites/laserbeam.spr")     precache_sound("weapons/electro5.wav")     precache_sound("weapons/xbow_hitbod2.wav")     precache_model("models/shmod/BlackKnight_v_knife.mdl") } //---------------------------------------------------------------------------------------------- public BlackKinght_init() {     new temp[128]     // First Argument is an id     read_argv(1,temp,5)     new id = str_to_num(temp)     // 2nd Argument is 0 or 1 depending on whether the id has BlackKinght powers     read_argv(2,temp,5)     new hasPowers=str_to_num(temp)     g_hasBlackKinghtPower[id] = (hasPowers!=0)     if (g_hasBlackKinghtPower[id]) {         gPlayerUltimateUsed[id] = false         laser_shots[id] = get_cvar_num("BlackKinght_laser_ammo")     } } //---------------------------------------------------------------------------------------------- public BlackKinght_death() {     new id = read_data(2)     if ( id < 0 || id > SH_MAXSLOTS ) return     remove_task(id+25735) } //---------------------------------------------------------------------------------------------- public BlackKinght_damage(id) {     if (!shModActive() ) return PLUGIN_CONTINUE     new damage = read_data(2)     new weapon, bodypart, attacker = get_user_attacker(id, weapon, bodypart)         if ( attacker <=0 || attacker>SH_MAXSLOTS ) return PLUGIN_CONTINUE         if ( g_hasBlackKinghtPower[attacker] && weapon == CSW_KNIFE && is_user_alive(id) )     {        // do extra damage        new extraDamage = floatround(damage * get_cvar_float("BlackKinght_knifemult") - damage)        shExtraDamage( id, attacker, extraDamage, "Sabre Skill" )     }     return PLUGIN_CONTINUE } //---------------------------------------------------------------------------------------------- public newRound(id) {     if ( !hasRoundStarted() ) {         laser_shots[id] = get_cvar_num("BlackKinght_laser_ammo")         gPlayerUltimateUsed[id] = false     } } //---------------------------------------------------------------------------------------------- public knife(id) {   if ( !is_user_alive(id) ) return PLUGIN_CONTINUE   Entvars_Set_String(id, EV_SZ_viewmodel, "models/shmod/BlackKnight_v_knife.mdl")   new iCurrent   iCurrent = FindEntity(-1,"weapon_knife")   while(iCurrent != -1) {     iCurrent = FindEntity(iCurrent,"weapon_knife")    }   return PLUGIN_HANDLED } //---------------------------------------------------------------------------------------------- // RESPOND TO KEYDOWN public BlackKinght_kd() {     if ( !hasRoundStarted() ) return PLUGIN_HANDLED     // First Argument is an id with BlackKinght Powers!     new temp[6]     read_argv(1,temp,5)     new id = str_to_num(temp)     if ( !is_user_alive(id) ) return PLUGIN_HANDLED     if ( laser_shots[id] <= 0 ) {         client_print(id,print_center,"No BlackKinght Shots Left" )         playSoundDenySelect(id)         return PLUGIN_HANDLED     }     if ( gPlayerUltimateUsed[id] ) {         playSoundDenySelect(id)         return PLUGIN_HANDLED     }     // Remember this weapon...     new clip,ammo,weaponID = get_user_weapon(id,clip,ammo)     gLastWeapon[id] = weaponID     // switch to knife     engclient_cmd(id,"weapon_knife")     fire_laser(id)  // 1 immediate shot     if (get_cvar_float("BlackKinght_mulishot") > 0.0)     set_task( get_cvar_float("BlackKinght_mulishot"), "fire_laser_task", id+25735, "", 0, "b")  //delayed shots     return PLUGIN_HANDLED } //---------------------------------------------------------------------------------------------- public BlackKinght_ku() {     // First Argument is an id with BlackKinght Powers!     new temp[6]     read_argv(1,temp,5)     new id = str_to_num(temp)     remove_task(id+25735)     // Use the ultimate     ultimateTimer(id, get_cvar_float("BlackKinght_cooldown") )     // Switch back to previous weapon...     if ( gLastWeapon[id] != CSW_KNIFE ) shSwitchWeaponID( id, gLastWeapon[id] ) } //---------------------------------------------------------------------------------------------- public laserEffects(id, aimvec[3] ) {     new origin[3]     new decal_id = burn_decal[random_num(0,4)]     emit_sound(id,CHAN_ITEM, "weapons/electro5.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)     get_user_origin(id, origin, 1)     // DELIGHT     message_begin( MSG_BROADCAST,SVC_TEMPENTITY)     write_byte( 27 )     write_coord( origin[0] ) //pos     write_coord( origin[1] )     write_coord( origin[2] )     write_byte( 10 )     write_byte( 250 ) // r, g, b     write_byte( 0 ) // r, g, b     write_byte( 0 ) // r, g, b     write_byte( 2 ) // life     write_byte( 1 ) // decay     message_end()     //BEAMENTPOINTS     message_begin( MSG_BROADCAST,SVC_TEMPENTITY)     write_byte ( 0 )     //TE_BEAMENTPOINTS 0     write_coord(origin[0])     write_coord(origin[1])     write_coord(origin[2])     write_coord(aimvec[0])     write_coord(aimvec[1])     write_coord(aimvec[2])     write_short( laser )     write_byte( 1 ) // framestart     write_byte( 5 ) // framerate     write_byte( 2 ) // life     write_byte( 40 ) // width     write_byte( 0 ) // noise     write_byte( 250 ) // r, g, b     write_byte( 0 ) // r, g, b     write_byte( 0 ) // r, g, b     write_byte( 200 ) // brightness     write_byte( 200 ) // speed     message_end()     //Sparks     message_begin( MSG_PVS, SVC_TEMPENTITY)     write_byte( 9 )     write_coord( aimvec[0] )     write_coord( aimvec[1] )     write_coord( aimvec[2] )     message_end()     //Smoke     message_begin( MSG_BROADCAST,SVC_TEMPENTITY)     write_byte( 5 ) // 5     write_coord(aimvec[0])     write_coord(aimvec[1])     write_coord(aimvec[2])     write_short( smoke )     write_byte( 22 )  // 10     write_byte( 10 )  // 10     message_end()     if(get_cvar_num("BlackKinght_laser_burndecals") == 1) {         //TE_GUNSHOTDECAL         message_begin( MSG_BROADCAST,SVC_TEMPENTITY)         write_byte( 109 ) // decal and ricochet sound         write_coord( aimvec[0] ) //pos         write_coord( aimvec[1] )         write_coord( aimvec[2] )         write_short (0) // I have no idea what thats supposed to be         write_byte (decal_id) //decal         message_end()     } } //---------------------------------------------------------------------------------------------- public fire_laser_task(id) {     id -= 25735     fire_laser(id) } //---------------------------------------------------------------------------------------------- public fire_laser(id) {     new aimvec[3]     new tid,tbody     new FFOn = get_cvar_num("mp_friendlyfire")     if( !is_user_alive(id) ) return PLUGIN_HANDLED     if ( laser_shots[id] <= 0 ) {         client_print(id,print_center,"No BlackKinght Shots Left" )         playSoundDenySelect(id)         return PLUGIN_HANDLED     }     // Make sure still on knife     new clip,ammo,weaponID = get_user_weapon(id,clip,ammo)     if ( weaponID != CSW_KNIFE ) engclient_cmd(id,"weapon_knife")     // Warn How many Blasts Left...     laser_shots[id]--     if(laser_shots[id] < 6) client_print(id,print_center,"Warning: %d BlackKinght Shots Left", laser_shots[id] )     get_user_origin(id,aimvec,3)     laserEffects(id, aimvec)     get_user_aiming(id,tid,tbody,9999)     if( tid > 0 && tid < 33 && ( FFOn || get_user_team(id)!=get_user_team(tid) ) )     {         emit_sound(tid,CHAN_BODY, "weapons/xbow_hitbod2.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)         // Determine the damage         new damage         switch(tbody) {             case 1: damage = h1_dam             case 2: damage = h2_dam             case 3: damage = h3_dam             case 4: damage = h4_dam             case 5: damage = h4_dam             case 6: damage = h6_dam             case 7: damage = h6_dam         }         // Deal the damage...         shExtraDamage(tid, id, damage, "BlackKinght Laser")     }     return PLUGIN_CONTINUE } //---------------------------------------------------------------------------------------------- public client_disconnect(id) {     // stupid check but lets see     if ( id <=0 || id > 32 ) return     // Yeah don't want any left over residuals     remove_task(id+25735) } //----------------------------------------------------------------------------------------------

Srry about other post plz delete the other one i put it in wrong section.srry again
__________________
Cs 1.6 - SuperHero Mod, 25 Levels ,Fast Download - 66.210.54.39:27015
imported_HOMiE is offline
Send a message via MSN to imported_HOMiE
imported_HOMiE
Senior Member
Join Date: Feb 2005
Old 03-14-2005 , 21:05  
Reply With Quote #2

i need help
__________________
Cs 1.6 - SuperHero Mod, 25 Levels ,Fast Download - 66.210.54.39:27015
imported_HOMiE is offline
Send a message via MSN to imported_HOMiE
imported_FireWalker877
Member
Join Date: Jun 2004
Location: Memphis, TN
Old 03-14-2005 , 21:10  
Reply With Quote #3

I don't believe anyone here has the certifications to give you the type of help you need... I'll take a look.

EDIT: I think the problem is that you never called the knife function. And btw, you might use find and replace to change kinght (sic) to knight.
__________________
Get Your Free 60 GB iPod here: http://premiumipods.freepay.com/?r=21092500

^ea^ Superhero Domain: 24.145.238.133:27015
imported_FireWalker877 is offline
imported_HOMiE
Senior Member
Join Date: Feb 2005
Old 03-14-2005 , 21:27  
Reply With Quote #4

lol i know i spelled it wrong but its not that....the hero takes affect in the game but i dont see a different knife model
__________________
Cs 1.6 - SuperHero Mod, 25 Levels ,Fast Download - 66.210.54.39:27015
imported_HOMiE is offline
Send a message via MSN to imported_HOMiE
vittu
SuperHero Moderator
Join Date: Oct 2004
Location: L.A. County, CA
Old 03-14-2005 , 21:58  
Reply With Quote #5

I'm not helping with model changing rips anymore, I'm so sick of these and would rather they not be posted in the heroes section....


but, you need a CurWeapon event to check what weapon you have. Look in other weapon model changing heroes in the plugin_init...
vittu is offline
Send a message via AIM to vittu Send a message via MSN to vittu Send a message via Yahoo to vittu
imported_HOMiE
Senior Member
Join Date: Feb 2005
Old 03-14-2005 , 23:32  
Reply With Quote #6

aww man vittu plz help me with this i havent asked for much just help me with this plz im really looking forword to have this hero and its model
__________________
Cs 1.6 - SuperHero Mod, 25 Levels ,Fast Download - 66.210.54.39:27015
imported_HOMiE is offline
Send a message via MSN to imported_HOMiE
Freecode
Never Fall Asleep
Join Date: Jan 2004
Old 03-14-2005 , 23:40  
Reply With Quote #7

*sigh* i should never have made Morpheus *sigh*
Freecode is offline
vittu
SuperHero Moderator
Join Date: Oct 2004
Location: L.A. County, CA
Old 03-14-2005 , 23:46  
Reply With Quote #8

Quote:
Originally Posted by Freecode
*sigh* i should never have made Morpheus *sigh*
haha I got myself thinking I should have never made Master Chief, I opened the floodgate for playermodel heroes...
vittu is offline
Send a message via AIM to vittu Send a message via MSN to vittu Send a message via Yahoo to vittu
imported_HOMiE
Senior Member
Join Date: Feb 2005
Old 03-14-2005 , 23:52  
Reply With Quote #9

i didnt want this hero cause of morpheus and masterchief i wanted it cause its my first hero and it's with models too. i just wanted some help
__________________
Cs 1.6 - SuperHero Mod, 25 Levels ,Fast Download - 66.210.54.39:27015
imported_HOMiE is offline
Send a message via MSN to imported_HOMiE
kanu | DarkPredator
Senior Member
Join Date: Apr 2005
Old 03-15-2005 , 00:58  
Reply With Quote #10

ugh... im so sorry vittu, i couldnt help it...

here homie, instead of using that weird code that doesnt work (where did you get that from?) use vittu's uber code:

Code:
public switchmodel(id) {     if ( !is_user_alive(id) || !gHasChuckyPowers[id] ) return     //If user is holding a shield do not change model, since we don't have one with a shield     new v_mdl[32]     Entvars_Get_String(id, EV_SZ_viewmodel, v_mdl, 31)     if ( containi(v_mdl, "v_shield_") != -1) return     new wpnid = read_data(2)     if (wpnid == CSW_KNIFE) {         // Weapon Model change thanks to [CCC]Taz-Devil         Entvars_Set_String(id, EV_SZ_viewmodel, "models/shmod/chucky_knife.mdl")     } } //---------------------------------------------------------------------------------------------- public weaponChange(id) {     if ( !gHasChuckyPowers[id] || !shModActive() ) return     new wpnid = read_data(2)     if ( wpnid == CSW_KNIFE ) switchmodel(id) } //----------------------------------------------------------------------------------------------

the code you used was really messed:

Code:
public knife(id) {   if ( !is_user_alive(id) ) return PLUGIN_CONTINUE   Entvars_Set_String(id, EV_SZ_viewmodel, "models/shmod/BlackKnight_v_knife.mdl")   new iCurrent   iCurrent = FindEntity(-1,"weapon_knife")   while(iCurrent != -1) {     iCurrent = FindEntity(iCurrent,"weapon_knife")    }   return PLUGIN_HANDLED } //----------------------------------------------------------------------------------------------
__________________
Dark | Predator
kanu | DarkPredator 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 14:07.


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