Go Back   EQEmulator Home > EQEmulator Forums > Archives > Archive::Development > Archive::Quests

Archive::Quests Archive area for Quests's posts that were moved here after an inactivity period of 90 days.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 05-17-2004, 02:52 AM
cofruben
Old-EQEmu Developer
 
Join Date: Oct 2002
Location: Spain
Posts: 323
Default

to change stats via perl command:

add this to client.cpp:
Code:
void Client::SetStat(int8 type,sint16 number){
        // Cofruben: Setstat function
        if(type>STAT_DISEASE){
                printf("Error in Client::SetStat, received invalid type of: %i\n",type);
                return;
        }
        switch(type){
                case STAT_STR:
                        m_pp.STR=number;
                        break;
                case STAT_STA:
                        m_pp.STA=number;
                        break;
                case STAT_AGI:
                        m_pp.AGI=number;
                        break;
                case STAT_DEX:
                        m_pp.DEX=number;
                        break;
                case STAT_INT:
                        m_pp.INT=number;
                        break;
                case STAT_WIS:
                        m_pp.WIS=number;
                        break;
                case STAT_CHA:
                        m_pp.CHA=number;
                        break;
        }
}
add this to client.h
Code:
void    SetStat(int8 type,sint16 number); //cofruben:-For setting stats.
now,you can make a perl command that calls that client function.For example add this to a perl command.
mob->CastToClient()->SetStat(0,70); //sets 70 to STR
or
mob->CastToClient()->SetStat(1,65); //sets 65 to STA.
Reply With Quote
 


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 11:28 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3