New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lightning can now be fired from traps manually #3211
Conversation
src/player_instances.c
Outdated
external_activate_trap_shot_at_angle(thing, player->acamera->orient_a, thing_get(player->hand_thing_idx)); | ||
struct TrapStats* trapstat = &game.conf.trap_stats[thing->model]; | ||
shotst = get_shot_model_stats(trapstat->created_itm_model); | ||
struct Thing* trgtng = ((shotst->model_flags & ShMF_Boulder) != 0) ? INVALID_THING : get_nearest_enemy_creature_in_sight_and_range_of_trap(thing); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now you hardcoded it on the shot model, that is not so very nice. Would this not be a lot better to link to TriggerType 1?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I'm reading it I think it's coded with the Boulder property, not the shot model, isn't?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I'm reading it I think it's coded with the Boulder property, not the shot model, isn't?
Yes, it's the Boulder model flag, not the model itself.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, indeed better. But still begs the question what we want for the other 90-degree triggered traps, of which by default there are none,...
Would be nice I think if at least it looks in the correct general direction you slap in for the 90-degree angles, or do you disagree?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've no idea how that can be done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, I will test it like this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@AdamPlenty I pushed a commit putting all the power in the hands of the mapmaker. How is that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@AdamPlenty I pushed a commit putting all the power in the hands of the mapmaker. How is that?
It doesn't work :(. I cannot slap traps whose Slappable is set to 2.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it does
0a58c78
to
4797a6f
Compare
…eperfx into TrapShootLightning
Fixes #3210