View Single Post
Author Message
NiQu
Veteran Member
Join Date: Nov 2009
Old 12-05-2009 , 01:20   Action Script for XP Block
Reply With Quote #1

This is the action needed to make an xp block into blockmaker to work with exolents hns xp mod

PHP Code:
action_XPBLOCK(idOverrideTimerent)
{
    new 
Float:fTime halflife_time();
    if (
fTime >= gfXPNextUse[id] || OverrideTimer)
    {
        if(
cs_get_user_team(id) == CS_TEAM_T)
        {
            new 
szProperty1[33];
            
Get_BlockProperty(ent1szProperty1);
            
            
hnsxp_add_user_xpidstr_to_num(szProperty1) );
            
gfXPNextUse[id] = fTime 170;
            
set_hudmessage(gHudRedgHudGreengHudBluegfTextXgfTextYgHudEffectsgfHudFxTimegfHudHoldTimegfHudFadeInTimegfHudFadeOutTimegHudChannel);
            
show_hudmessage(id"YOU GOT A FEW MORE XP!");
        }
    }

Also, to use this you need to use his API thing, im using this on my server so dont say this dont work.

Tested On: FSCM ( Flaxans Course Maker )(a remake of bunnyhop course maker and blockmaker ).

Oh, and another thing.. if u look into this code you can see "( id, str_to_num(szProperty1) );" wich means you need a blockmaker that has "Set Properties" item in the menu.

For an example: i belive BCM5 has it
NiQu is offline