Thread: How to add attack styles instead of punch, kick, block + how to add special bar?

Results 1 to 8 of 8
  1. #1 How to add attack styles instead of punch, kick, block + how to add special bar? 
    Registered Member Archeon's Avatar
    Join Date
    Jun 2015
    Posts
    345
    Thanks given
    17
    Thanks received
    5
    Rep Power
    2
    As the title says, I add custom weapons and some weapons don't have the special bar neither the attack styles. They rather have only punch, kick and block most of the time.
    So how do I add this?
    This is for a 718 server.
    Reply With Quote  
     

  2. #2  
    Banned

    Join Date
    Jul 2011
    Posts
    1,767
    Thanks given
    493
    Thanks received
    425
    Rep Power
    0
    u have to do it cache sided I believe, there is a tutorial for it try and search 4 ti
    Reply With Quote  
     

  3. #3  
    Registered Member
    hc747's Avatar
    Join Date
    Dec 2013
    Age
    26
    Posts
    1,474
    Thanks given
    3,312
    Thanks received
    691
    Rep Power
    1098
    Change the CS data values; I modified frosties cache editor to do this by using the following code (itemeditor.java):
    Code:
    private void specialSave() {
           try {
               final int RENDER = 644, STYLE = 686, KEY = STYLE;
               final String[] EQUIPMENT_GENERAL = {
                       //your material type here (bronze etc)
                       },
                       EQUIPMENT_SPECIFIC = {
                       //your item type here (scimitar etc)
                       };
               final int[] VALUES = {
                       //your value here (String, integer, etc etc)
                       };
               skip: for (int i = 0; i < 30000; i++) {
                    final ItemDefinitions definitions = ItemDefinitions.getItemDefinition(ItemSelection.STORE, i);
                    if (definitions != null && definitions.id != -1) {
                       for (int e = 0; e < EQUIPMENT_GENERAL.length; e++) {
                           if (definitions.name == null || definitions.name == "")
                               continue skip;
                           if (definitions.name.toLowerCase().contains(EQUIPMENT_GENERAL[e])) {
                               for (int v = 0; v < EQUIPMENT_SPECIFIC.length; v++) {
                                   if (definitions.name.toLowerCase().contains(EQUIPMENT_SPECIFIC[v])) {
                                       if (definitions.clientScriptData != null) {
                                           if(definitions.clientScriptData.containsKey(KEY)) {
                                               Object previous = definitions.clientScriptData.get(KEY);
                                               definitions.clientScriptData.put(KEY, VALUES[v]);
                                               Main.log("ItemDefinitions","Name: "+definitions.name+", Id: "+definitions.id+", Key: "+KEY+", Value: "+previous+" changed to "+definitions.clientScriptData.get(KEY));
                                               if (this.is != null) {
                                                   definitions.write(ItemSelection.STORE);
                                                   final ItemSelection is = this.is;
                                                   is.updateItemDefs(definitions);
                                               } else
                                                   Main.log("ERROR","ITEM_SELECTION EQUAL TO NULL");
                                           }
                                       }
                                   }
                               }
                           }
                       }
                    }
                }
    } catch (Exception var201) {
       Main.log("ItemEditor", "Cannot save. Please check for mistypes.");
    }
    }
    Reply With Quote  
     

  4. #4  
    Registered Member
    Join Date
    Apr 2014
    Posts
    138
    Thanks given
    9
    Thanks received
    9
    Rep Power
    30
    Yeah its cache sided. Pretty easy after you do it once. Gl
    Rune-sever is the reason why I'm failing math
    Reply With Quote  
     

  5. #5  
    Registered Member Archeon's Avatar
    Join Date
    Jun 2015
    Posts
    345
    Thanks given
    17
    Thanks received
    5
    Rep Power
    2
    Quote Originally Posted by Tristam View Post
    u have to do it cache sided I believe, there is a tutorial for it try and search 4 ti
    Can you give me the tutorial?
    Reply With Quote  
     

  6. #6  
    Contributor

    clem585's Avatar
    Join Date
    Sep 2013
    Posts
    3,788
    Thanks given
    706
    Thanks received
    702
    Rep Power
    570
    Quote Originally Posted by Aragorn7 View Post
    Can you give me the tutorial?
    Well just open up the item with Frosty's editor and change this:



    Enter a value and then click save.

    You can find the "value" by looking at what client script #686 is on other weapons.
    Project thread
    Reply With Quote  
     

  7. #7  
    Registered Member Archeon's Avatar
    Join Date
    Jun 2015
    Posts
    345
    Thanks given
    17
    Thanks received
    5
    Rep Power
    2
    Quote Originally Posted by clem585 View Post
    Well just open up the item with Frosty's editor and change this:



    Enter a value and then click save.

    You can find the "value" by looking at what client script #686 is on other weapons.
    Ty, it worked. Do you also know the client script for the special bar?
    Reply With Quote  
     

  8. #8  
    Contributor

    clem585's Avatar
    Join Date
    Sep 2013
    Posts
    3,788
    Thanks given
    706
    Thanks received
    702
    Rep Power
    570
    Quote Originally Posted by Aragorn7 View Post
    Ty, it worked. Do you also know the client script for the special bar?
    Hmmm. Try script data #2195 != null && != 0 ?
    Project thread
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Replies: 2
    Last Post: 02-06-2015, 01:00 AM
  2. how to change attack styles? [667]
    By alon in forum Help
    Replies: 20
    Last Post: 03-13-2014, 07:07 PM
  3. Replies: 2
    Last Post: 01-13-2014, 10:37 PM
  4. PI - Punch, Kick, Block
    By infallible in forum Help
    Replies: 23
    Last Post: 03-10-2011, 01:34 PM
  5. Replies: 14
    Last Post: 01-08-2009, 12:34 AM
Tags for this Thread

View Tag Cloud

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •