Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
LOP Heroes Edition
Author: Vladaar
Submitted by: Vladaar
Heroes sound extras
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.3
Author: Vladaar
Submitted by: Vladaar
Memwatch
Author: Johan Lindh
Submitted by: Vladaar
Beastmaster 6D sound files
Author: Vladaar
Submitted by: Vladaar
Users Online
CommonCrawl, Yahoo!, Yandex, Bing

Members: 0
Guests: 15
Stats
Files
Topics
Posts
Members
Newest Member
476
3,696
19,216
602
ServerFailure
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Codebases » SmaugFUSS » Bug in violence_update( )
Forum Rules | Mark all | Recent Posts

Bug in violence_update( )
< Newer Topic :: Older Topic >

Pages:<< prev 1 next >>
Post is unread #1 Jan 14, 2017, 5:43 pm   Last edited Jan 14, 2017, 5:53 pm by GatewaySysop
Go to the top of the page
Go to the bottom of the page

GatewaySysop
Conjurer
GroupMembers
Posts360
JoinedMar 7, 2005

I'm not seeing options for tagging anymore, and emoticons still don't work, so not really able to post the bug here. Think you might have some more kinks yet to work out. If I can edit later, I will try that. Otherwise will start a new topic.
       
* #2 Jan 15, 2017, 9:56 am
Go to the top of the page
Go to the bottom of the page

GatewaySysop
Conjurer
GroupMembers
Posts360
JoinedMar 7, 2005

Okay, giving this another shot after the forum fix. Thanks Samson! :smile:

In fight.c, violence_update( ), there is this bit regarding non-autonomous mobs potentially switching PC tanks:
            /*
             *   Group Fighting Styles Support:
             *   If ch is tanking
             *   If rch is using a more aggressive style than ch
             *   Then rch is the new tank   -h
             */
            if( ( !IS_NPC(ch) && !IS_NPC(rch) )
              &&( rch!=ch                     )
              &&( rch->fighting               )
              &&( who_fighting(rch->fighting->who) == ch    )
              &&( !xIS_SET( rch->fighting->who->act, ACT_AUTONOMOUS ) )
              &&( rch->style < ch->style      )
              )
            {
                 rch->fighting->who->fighting->who = rch; 

            }


Shouldn't that instead look like this, so we recalculate fight->xp, fight->align, fight->time_skilled and such, for the new tank? :huh:

            /*
             *   Group Fighting Styles Support:
             *   If ch is tanking
             *   If rch is using a more aggressive style than ch
             *   Then rch is the new tank   -h
             */
            if( ( !IS_NPC(ch) && !IS_NPC(rch) )
              &&( rch!=ch                     )
              &&( rch->fighting               )
              &&( who_fighting(rch->fighting->who) == ch    )
              &&( !xIS_SET( rch->fighting->who->act, ACT_AUTONOMOUS ) )
              &&( rch->style < ch->style      )
              &&( rch->num_fighting < max_fight(rch) )
              )
            {  
                    stop_fighting( rch->fighting->who, FALSE );
	            set_fighting( rch->fighting->who, rch );  
            }


       
Post is unread #3 Jan 18, 2017, 2:43 pm
Go to the top of the page
Go to the bottom of the page

Sadiq
Fledgling
GroupMembers
Posts24
JoinedJan 7, 2010

And another good catch! You are on a roll! :tongue:
       
Post is unread #4 Jan 18, 2017, 9:20 pm
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,636
JoinedJan 1, 2002

Have you guys thought about making sure these get submitted to GitHub?
       
Post is unread #5 Jan 20, 2017, 5:34 am
Go to the top of the page
Go to the bottom of the page

Sadiq
Fledgling
GroupMembers
Posts24
JoinedJan 7, 2010

Samson said:

Have you guys thought about making sure these get submitted to GitHub?


I'm not adverse to the idea, but I have never used GitHub. I will have to go and figure out how to submit changes. :redface:
       
Post is unread #6 Jan 20, 2017, 1:50 pm
Go to the top of the page
Go to the bottom of the page

GatewaySysop
Conjurer
GroupMembers
Posts360
JoinedMar 7, 2005


Sadiq said:

Samson said:

Have you guys thought about making sure these get submitted to GitHub?


I'm not adverse to the idea, but I have never used GitHub. I will have to go and figure out how to submit changes. :redface:


Likewise here, to be honest. Will have to check it out when I get a chance!
       
Post is unread #7 Jan 28, 2017, 7:04 am
Go to the top of the page
Go to the bottom of the page

Sadiq
Fledgling
GroupMembers
Posts24
JoinedJan 7, 2010

Samson said:

Have you guys thought about making sure these get submitted to GitHub?


I made an account on GitHub (Username is Radamanthas - 'Sadiq' was taken :p ) and I *think* I got it worked out. I forked the repo into my account made the changes then sent a pull request. Someone please let me know if I did it all correctly, or if I need to do something else. Thanks!
       
Post is unread #8 Jan 28, 2017, 2:41 pm
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,636
JoinedJan 1, 2002

Looks like you got it right, but you forked from the main branch that only Kayle has access to rather than my fork, which is here: https://github.com/Arthmoor/SmaugFUSS

That's fine though, because eventually it would need to move up to his branch anyway.
       
Post is unread #9 Jan 28, 2017, 3:54 pm
Go to the top of the page
Go to the bottom of the page

Sadiq
Fledgling
GroupMembers
Posts24
JoinedJan 7, 2010

Samson said:

Looks like you got it right, but you forked from the main branch that only Kayle has access to rather than my fork, which is here: https://github.com/Arthmoor/SmaugFUSS

That's fine though, because eventually it would need to move up to his branch anyway.


Sorry, I'm rather green about these things :p

Sent a pull request to your fork, as well :)
       
Pages:<< prev 1 next >>