AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   Solved XP For BB Zombies (https://forums.alliedmods.net/showthread.php?t=339476)

crystal xtreme 09-12-2022 11:01

XP For BB Zombies
 
2 Attachment(s)
Hi.
I need add this feature in my basebuilder mod:
1. Classic Zombie [ Free ]
2. Fast Zombie [ 500 XP ]
3. Jumper Zombie [ 1200 XP ]
4. Tanker Zombie [ 1600 XP ]

When players reaches the XP which we set for each zombies then he automatically unlocked the zombie.
Example: Any player reaches 500 XP then he automatically unlocked Fast Zombie ( permanent, not just for once ).
I'm using Base Builder v6.5 by Tirant and Using XP + Level + Rank System v2.2 by CrAzY MaN

Link Of XP + Level + Rank System v2.2 https://forums.alliedmods.net/showpo...73&postcount=1

I attached the basebuilder65.sma and bb_classes65.sma !!

SORRY FOR BAD ENGLISH :D

Supremache 09-14-2022 02:17

Re: [REQ] XP For BB Zombies
 
1 Attachment(s)
I used OciXCrom's ranking system because the plugin that you attached does not contain natives

Need to replace this code in the include file
PHP Code:

 bb_register_zombie_class(const name[], const info[], const model[], const clawmodel[], hpspeedFloat:gravityFloat:knockbackadminflagscredits

To
PHP Code:

 bb_register_zombie_class(const name[], const info[], const model[], const clawmodel[], hpspeedFloat:gravityxpadminflagscredits 

-> Classes:

Code:

#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>
#include <basebuilder>

enum _:eRegisterZombies
{
        Name[ 32 ],
        Info[ 32 ],
        Model[ 64 ],
        ClawModel[ 64 ],
        Health,
        Speed,
        Float:Gravity,
        XP,
        Access
}

new const g_szZombie[ ][eRegisterZombies] =
{
        { "Clasic", ">>Balanced<<", "bb_clasic", "v_bloodyhands", 4000, 260, 1.0, 0, ADMIN_ALL },
        { "Fast Zombie", "Speed++", "bb_fast", "v_bloodyhands", 3500, 325, 1.0, 500, ADMIN_ALL },
        { "Jumper Zombie", "Jump++", "bb_jumper", "v_bloodyhands", 4300, 285, 0.5, 1200, ADMIN_ALL },
        { "Tanker Zombie", "VESTHELM", "bb_tanker", "v_bloodyhands", 5000, 210, 1.0, 1600, ADMIN_ALL },
}

public plugin_precache( )
{
        register_plugin("BaseBuilder: ZClasses", "1.0", "Supremache");
       
        for( new i; i < sizeof( g_szZombie ); i++ )
        {
                g_szZombie[ i ][ 0 ] = bb_register_zombie_class
                (
                        g_szZombie[ i ][ Name ],
                        g_szZombie[ i ][ Info ],
                        g_szZombie[ i ][ Model ],
                        g_szZombie[ i ][ ClawModel ],
                        g_szZombie[ i ][ Health ],
                        g_szZombie[ i ][ Speed ],
                        g_szZombie[ i ][ Gravity ],
                        g_szZombie[ i ][ XP],
                        g_szZombie[ i ][ Access ]
                )
        }
}

public bb_zombie_class_set( id, iClass )
{
        if( iClass == g_szZombie[ 3 ][ 0 ] ) /* 3 = Tanker Zm*/
        {
                give_item(id, "item_assaultsuit");
                cs_set_user_armor(id, 200, CS_ARMOR_VESTHELM);
        }
}


crystal xtreme 09-14-2022 08:15

Re: [REQ] XP For BB Zombies
 
I CAN'T COMPILE IT!

//AMXXPC compile.exe
// by the AMX Mod X Dev Team


//// bb_classes65.sma
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(9) : error 017: undefined symbol "MAX_NAME_LENGTH"
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(22) : warning 228: length of initialler exceeds size of the enum field
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(22) : warning 228: length of initialler exceeds size of the enum field
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(22) : error 018: initialization data exceeds declared size
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(26 -- 28) : error 008: must be a constant expression; assumed zero
// E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\bb_cl asses65.sma(34 -- 43) : warning 213: tag mismatch
//
// 3 Errors.
// Could not locate output file E:\Games\Counter-Strike\cstrike\addons\amxmodx\scripting\compi led\bb_classes65.amx (compile failed).
//
// Compilation Time: 0.28 sec
// ----------------------------------------

Supremache 09-14-2022 11:57

Re: [REQ] XP For BB Zombies
 
Quote:

Originally Posted by crystal xtreme (Post 2788827)
I CAN'T COMPILE IT!

Because you are using old version, try it now


All times are GMT -4. The time now is 01:10.

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