Official Community Forums
 
HomeHome  FAQFAQ  SearchSearch  MemberlistMemberlist  UsergroupsUsergroups  RegisterRegister  Log in  The Wiki  Website  github Project  

Share | 
 

 Mars.jar confusion

View previous topic View next topic Go down 
AuthorMessage
AthlonJedi
Administrator
Administrator
avatar

Posts : 213
Join date : 2012-07-19
Location : Walkerton, Indiana

PostSubject: Mars.jar confusion   Wed 29 May - 8:35

I have some confusion as I am not that good with java yet. In this tutorial :

http://www.multiversemmo.com/site/w/index.php/Add_in_a_Release_box_in_the_UI_that_shows_up_upon_Death

There is a section that says:

Quote :

The final thing you will want to add is the setting of health upon releasing. By default when you release you come back with only 1hp. The best way to fix this is to go into the CombatPlugin.java file, located in MARS, and edit the ReleaseObjectHook code.

We want to replace this line here:
Code:

info.statSetBaseValue("health", 1);
with:
Code:

int currentmaxhp = info.statGetCurrentValue("health-max");
int currenthp =  = currentmaxhp / 2;
info.statSetBaseValue("health", currenthp);


but when I look in Mars.jar in the CombatPlugin.class file with netbeans all I see is this:

Code:

class ReleaseObjectHook implements multiverse.server.engine.Hook {

        ReleaseObjectHook() {
            //compiled code
            throw new RuntimeException("Compiled Code");
        }


I am thinking I am looking in the wrong place but, I dont know where to find the accual code I am supposed to change.

any pointers would be appreciated!
Back to top Go down
AthlonJedi
Administrator
Administrator
avatar

Posts : 213
Join date : 2012-07-19
Location : Walkerton, Indiana

PostSubject: Re: Mars.jar confusion   Wed 29 May - 11:07

Nevermind, I found it,

It is in src folder lol
Back to top Go down
 
Mars.jar confusion
View previous topic View next topic Back to top 
Page 1 of 1
 Similar topics
-
» Mars
» Marry You Lyrics ~ Bruno Mars
» Mars chess engine
» [GURPS!] campaigns, Setting, Stuff wanted to try with GURPS
» DB´s Battlefleet Gothic BatReps

Permissions in this forum:You cannot reply to topics in this forum
 :: Development :: Getting Started-
Jump to: