Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old November 4, 2020, 21:16   #131
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 55
Posts: 8,552
Donated: $60
Nick will become famous soon enough
Quote:
Originally Posted by PowerWyrm View Post
In gauntlet_gen():

Code:
	int x_size = (z_info->dungeon_wid - gauntlet_wid) / 2 -
		randint0(45 - gauntlet_wid);
This can still break the x boundary in case randint0() returns 0. Changing this to randint1() works.
Thanks, that's what I meant.
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old November 5, 2020, 14:18   #132
DavidMedley
Knight
 
Join Date: Oct 2019
Posts: 828
DavidMedley is on a distinguished road
Throwing weapons occupying the quiver works only sporadically. I haven't been able to figure out the trick to it (I inscribe @v0).
DavidMedley is offline   Reply With Quote
Old November 5, 2020, 18:25   #133
Ingwe Ingweron
Veteran
 
Join Date: Jan 2009
Location: Manhattan Beach, CA
Posts: 1,980
Ingwe Ingweron is on a distinguished road
Quote:
Originally Posted by DavidMedley View Post
Throwing weapons occupying the quiver works only sporadically. I haven't been able to figure out the trick to it (I inscribe @v0).
Yeah, you must inscribe with the @v# to insert in quiver. Unlike FA, which asks on pickup whether you want to put a throwable item in the quiver.
__________________
“We're more of the love, blood, and rhetoric school. Well, we can do you blood and love without the rhetoric, and we can do you blood and rhetoric without the love, and we can do you all three concurrent or consecutive. But we can't give you love and rhetoric without the blood. Blood is compulsory. They're all blood, you see.”
― Tom Stoppard, Rosencrantz and Guildenstern are Dead
Ingwe Ingweron is offline   Reply With Quote
Old November 5, 2020, 18:57   #134
DavidMedley
Knight
 
Join Date: Oct 2019
Posts: 828
DavidMedley is on a distinguished road
Quote:
Originally Posted by DavidMedley View Post
(I inscribe @v0).
That's what I'm saying. I inscribe them and it works sporadically.
DavidMedley is offline   Reply With Quote
Old November 5, 2020, 21:20   #135
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 55
Posts: 8,552
Donated: $60
Nick will become famous soon enough
Quote:
Originally Posted by DavidMedley View Post
Throwing weapons occupying the quiver works only sporadically. I haven't been able to figure out the trick to it (I inscribe @v0).
When does it not work? I know there are difficulties if you also have ammo inscribed with @f0, but are there other cases?
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old November 9, 2020, 23:00   #136
sffp
Adept
 
Join Date: Apr 2020
Location: DC Area
Posts: 110
sffp is on a distinguished road
Running a half-orc blackguard, I just ran into a C++ error

I think I was trying to cast "Maim Foe"

Version 4.2.1
Attached Thumbnails
Click image for larger version

Name:	cpluspluserror.png
Views:	9
Size:	9.8 KB
ID:	1912  
sffp is offline   Reply With Quote
Old November 9, 2020, 23:25   #137
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 55
Posts: 8,552
Donated: $60
Nick will become famous soon enough
Quote:
Originally Posted by sffp View Post
I think I was trying to cast "Maim Foe"

Version 4.2.1
Excellent report, thanks - I think I can see the problem, and have filed a bug.
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old November 13, 2020, 11:52   #138
Sphara
Swordsman
 
Sphara's Avatar
 
Join Date: Oct 2016
Location: Finland
Posts: 391
Sphara is on a distinguished road
angband.live nightly, 13th Nov, account SPHARAGAIN, the game crashed immediately after descending from DL51 to DL52. I obviously cannot produce the savefile. Gwarl can certainly send it to a dev, if there is anything to send, without further permission from me.

"Ignoring illegal player location (35,216). Savefile corrupted - Couldn't load block dungeon"
Sphara is offline   Reply With Quote
Old November 25, 2020, 12:17   #139
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,815
PowerWyrm is on a distinguished road
Commit 3f9d411 has a lot of crash potential:
- if mob only has quest artifacts, get_random_monster_object() goes into endless loop
- if quest artifacts are at the end and the RNG picks them first, get_random_monster_object() also goes into endless loop

Probably a much simpler way to pick a random object would be:

Code:
static struct object *get_random_monster_object(struct monster *mon)
{
    struct object *obj, *pick = NULL;
    int i = 1;

    /* Pick a random object */
    for (obj = mon->held_obj; obj; obj = obj->next)
    {
        /* Check it isn't a quest artifact */
        if (obj->artifact && kf_has(obj->kind->kind_flags, KF_QUEST_ART))
            continue;

        if (one_in_(i)) pick = obj;
        i++;
    }

    return pick;
}
__________________
PWMAngband variant maintainer - check http://powerwyrm.monsite-orange.fr (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
PowerWyrm is offline   Reply With Quote
Old November 25, 2020, 14:34   #140
Pete Mack
Prophet
 
Join Date: Apr 2007
Location: Seattle, WA
Posts: 5,872
Donated: $40
Pete Mack is on a distinguished road
That code isn't even right. It will favor the first objects enormously.

You want to count down with probability, with P= 1/N for object 1 and p = 1 for object N. Even better, count the list without the quest artifacts, pick a random number between 1 an N, and count off til you get that object. As written, there are excessive calls to random.
Pete Mack is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Current master post 4.2.0 Nick Vanilla 463 June 5, 2020 04:31
Current master post-4.1.3 Nick Vanilla 505 June 16, 2019 01:26
Suggestion for Rangers (repost from master-post thread) Thraalbee Vanilla 1 April 13, 2019 19:08
Issues on current master Nick Vanilla 277 June 18, 2017 23:30
Bugs and complaints on current master Nick Vanilla 588 April 27, 2017 23:54


All times are GMT +1. The time now is 07:26.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.