Jump to content

Haziel

Content Moderator
  • Posts

    639
  • Joined

  • Last visited

  • Days Won

    88

Posts posted by Haziel

  1. You can use getcastledata command:

    *getcastledata("<map name>",<type of data>)
    *setcastledata "<map name>",<type of data>,<value>;
    
    This function returns the castle ownership information for the castle referred 
    to by its map name. Castle information is stored in `guild_castle` SQL table.
    
    Types of data correspond to `guild_castle` table columns:
    
     1 - `guild_id`   - Guild ID.
     2 - `economy`    - Castle Economy score.
     3 - `defense`    - Castle Defense score.
     4 - `triggerE`   - Number of times the economy was invested in today.
     5 - `triggerD`   - Number of times the defense was invested in today.
     6 - `nextTime`   - unused
     7 - `payTime`    - unused
     8 - `createTime` - unused
     9 - `visibleC`   - Is 1 if a Kafra was hired for this castle, 0 otherwise.
    10 - `visibleG0`  - Is 1 if the 1st guardian is present (Soldier Guardian)
    11 - `visibleG1`  - Is 1 if the 2nd guardian is present (Soldier Guardian)
    12 - `visibleG2`  - Is 1 if the 3rd guardian is present (Soldier Guardian)
    13 - `visibleG3`  - Is 1 if the 4th guardian is present (Archer Guardian)
    14 - `visibleG4`  - Is 1 if the 5th guardian is present (Archer Guardian)
    15 - `visibleG5`  - Is 1 if the 6th guardian is present (Knight Guardian)
    16 - `visibleG6`  - Is 1 if the 7th guardian is present (Knight Guardian)
    17 - `visibleG7`  - Is 1 if the 8th guardian is present (Knight Guardian)
    
    All types of data have their meaning determined by War of Emperium scripts, 
    with exception of:
     - `guild_id` that is always considered ID of the guild that owns the castle,
     - `defense` that is used in Guardians & Emperium HP calculations,
     - `visibleG` that is always considered to hold guardian presence bits.
    
    The 'setcastledata' command will behave identically, but instead of returning 
    values for the specified types of accessible data, it will alter them and cause 
    them to be sent to the char-server for storage.
    
    Changing Guild ID or Castle Defense will trigger additional actions, like 
    recalculating guardians' HP.

    In a Script, set an array with the list of all castles and make a loop checking the ID of the castle owner match the desired Guild check.

  2. if( agitcheck() || .@woe$ == "prtg_cas01" ) {

    What you're checking here is read is:

    IF war is happening OR the player is on "prtg_cas01", give points.
    | | symbol represents OR, so, IF would work if one of the following conditions is met.

  3. Very well, I had some spare time, so.

    -    script    hourly_point_main    -1,{
        
        OnInit:
            .max_hour = 5;
            .duration = 3600;
            .npc_name$ = strnpcinfo(3);
            bindatcmd "hourly",    .npc_name$ + "::OnCheck";
            end;
            
        OnClock0000:
            query_sql( "DELETE FROM acc_reg_num` WHERE `key` = '#daily_hour_count' AND `account_id` IN ( SELECT `account_id` FROM `char` WHERE `login` = 0 GROUP BY `account_id` ) " );
            addrid(0);
            #daily_hour_count = -1;
            
        OnUpdate:
            deltimer .npc_name$+"::OnUpdate";
            #daily_hour_count++;
            switch ( #daily_hour_count ) {
                case 1:
                    #CASHPOINT += 1;
                    getitem 512,1;
                    break;
                case 2:
                    #CASHPOINT += 2;
                    getitem 512,2;
                    break;
                case 3:
                    #CASHPOINT += 3;
                    getitem 512,3;
                    break;
                case 4:
                    #CASHPOINT += 4;
                    getitem 512,4;
                    break;
                case 5:
                    #CASHPOINT += 5;
                    getitem 512,6;
                    break;
                default: break;
            }
            
        OnPCLoginEvent:
            if ( #daily_hour_count < .max_hour ) {
                @timer = gettimetick(2) + .duration;
                addtimer ( .duration * 1000 ), .npc_name$+"::OnUpdate";
            }
            if ( #daily_hour_count )    dispbottom "[ Hourly Rewards ] " + #daily_hour_count + "/" + .max_hour + " hour" + ((#daily_hour_count > 1)?"s":"") + " played!",0x9ae2d7;
            end;
            
        OnCheck:
            .@min = (@timer - gettimetick(2))/60;
            .@sec = (@timer - gettimetick(2))%60;
            dispbottom "[ Hourly Rewards ] Your next reward will be achieved in " +
                        ((.@min)?            "[ " + .@min + " ] minute"         + ((.@min > 1)?"s":""):"") +
                        ((.@min && .@sec)?    " and ":"") +
                        ((.@sec)?            "[ " + .@sec + " ] second"    + ((.@sec > 1)?"s":""):"") +
                        "!",0x9ae2d7;
            end;            
    }

    I've made it on my own coding and aesthetic taste, adapt it as you wish.
    Use @hourly to check time left

    • Upvote 1
  4. [Arcturus] Lightning Guardian


    Hello again, rAthena.

    Years before the release of Ragnarök Online, Gravity made an RPG game called Arcturus.
    Due the similarities of the styles and structures, some content can be brought back to life on our beloved RO.

    Today I presente you one new Foe or Boss for your fields, instances or yet, quests: The Lightning Guardian!
    This is a free release, use it as you wish, but please, don't claim my work as yours, it took quite some effort to make this conversion.

    I'll try to make a release weekly, contact me if you want to support me by any way.
    Hope you all like it.

    Regards,
    Haziel


     

    • Upvote 10
  5. 4 minutes ago, Chemical Crush said:

    This is definitely not a lightmap issue.  Lightmaps dont reflect or land on models, this is a model issue.  I'm not sure what exactly because I don't use custom models, but it is definitely a model issue.  The only thing shadows appear on are textures, or walls, which are textures regardless.  I think there are some guides about custom models on Syo's channel but I'm not sure it brings up this issue, sadly.

    Sometimes I found some influences of lightmaps on models, but I might be also wrong.
    @Tio Akima I would love to take a look on those Custom Dragon Ball Job sprites, care to show me some previews?

  6. Use this command:

    *changebase <job ID number>{,<account ID>};
    
    This command will change a character's appearance to that of the specified job class. Nothing but appearance will change.
    The command will run for the invoking character unless an account ID is given.
    
    	changebase Job_Novice; // Changes player to Novice sprite.
    	changebase Class; // Changes player back to default sprite.



    On the Equip/Unequip part of the desired item, it might also need some OnLogin checks, not sure tho.

  7. You can set this configuration under: conf\battle\monster.conf
    Search for:

    mvp_tomb_enabled: yes

    That is a well known and numerous-times-answered question.
    Please, do a quick search before posting.

×
×
  • Create New...