View previous topic :: View next topic |
Author |
Message |
FunkySwerve
Joined: 02 Jun 2005 Posts: 377
|
Posted: Sun Mar 04, 2007 15:21 Post subject: |
|
|
scarface wrote: | It would only work if the attacker actually pulled of a hit, that's why we need an OnPhysical/SpellcastAt event. Using hides and on-hit isn't really going to help determine the first attacker because If the attacker misses, and the attackee hits first, wouldn't they be flagged as the first attacker? It's a decent suggestion but won't be much use in this PvP scenerio. |
Ah, cmon, now you're just nitpicking. That, plus a 'first damager' rule and you're set. Combine with a local set from the spellhook and you can pretty much always discern who's bs'ing. Course it'll be a moot point once virusman does his thing.
Funky |
|
Back to top |
|
|
scarface
Joined: 12 Jun 2005 Posts: 94 Location: Sweden
|
Posted: Sun Mar 04, 2007 20:37 Post subject: |
|
|
FunkySwerve wrote: | scarface wrote: | It would only work if the attacker actually pulled of a hit, that's why we need an OnPhysical/SpellcastAt event. Using hides and on-hit isn't really going to help determine the first attacker because If the attacker misses, and the attackee hits first, wouldn't they be flagged as the first attacker? It's a decent suggestion but won't be much use in this PvP scenerio. |
Ah, cmon, now you're just nitpicking. That, plus a 'first damager' rule and you're set. Combine with a local set from the spellhook and you can pretty much always discern who's bs'ing. Course it'll be a moot point once virusman does his thing.
Funky |
I'm not nitpicking at all mate I need a reliable way to determine the first attacker/hostile actor, and the way you suggested is by no means reliable for that scenerio, getting the first damager isn't going to tell us who attacked who first which is what we need and the major reason I need this event hooked. |
|
Back to top |
|
|
FunkySwerve
Joined: 02 Jun 2005 Posts: 377
|
Posted: Sun Mar 04, 2007 21:27 Post subject: |
|
|
Yeah...that's why the first damager rule. Anyway, looks like you'll get your plugin.
Funky |
|
Back to top |
|
|
milliorn
Joined: 03 Jun 2006 Posts: 29
|
Posted: Mon Mar 05, 2007 3:34 Post subject: |
|
|
ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. problem lies with lets say "effortless" rated players making first strike, failing, an impossible rated player auto-attacking back, to just a mage trying to stay alive yet perhaps not break a server rule about no effy killing. could say perhaps well why are the two in same area? well some modules perhaps have areas that overlap territory for one reason or another. another reason being in an arena enviroment also.
besides tracking down pickpocketing an having it dealt with scripts instead of logs be one less task an report a dm has to handle. imo most module teams wish for there dm's to have more room to be a dm, more so than a "cop". for those activites scripts are unbias, dont show any favortism, just flat out enforces a rule
thank you very much virusman for getting involved. when your done the time be worth the wait. now, just need someone to write up some code perhaps to hook it to the module an nwnx |
|
Back to top |
|
|
FunkySwerve
Joined: 02 Jun 2005 Posts: 377
|
Posted: Mon Mar 05, 2007 18:07 Post subject: |
|
|
milliorn wrote: | ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. |
As with most things, you can make up for engine shortcomings with well-crafted rules (for instance, first damager rather than first attacker). Of course, the plugin is preferable, I'm not naysaying that, I was merely suggesting an alternative for the meantime, but it sounds like you aren't interested. I'm also fairly certain the impossible rated player in your scenario would have to hostile the effy before he'd take an AoO.
Funky |
|
Back to top |
|
|
milliorn
Joined: 03 Jun 2006 Posts: 29
|
Posted: Mon Mar 05, 2007 18:12 Post subject: |
|
|
FunkySwerve wrote: | milliorn wrote: | ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. |
As with most things, you can make up for engine shortcomings with well-crafted rules (for instance, first damager rather than first attacker). Of course, the plugin is preferable, I'm not naysaying that, I was merely suggesting an alternative for the meantime, but it sounds like you aren't interested. I'm also fairly certain the impossible rated player in your scenario would have to hostile the effy before he'd take an AoO.
Funky |
perhaps true from reading what your saying. but, the point still is that effy's will go out an start fights with imp's to get killed an punish imps in some modules. basically they know they will not damage the imp, an depending on what build imp has, auto attack in some cases, will kill the effy, thus giving a false report. this is what im hoping to stamp out, by finding who initated the pvp period, same goes with pickpocket your logic most likely will work in most modules, but where pvp is very intense, the ability to enforce a no effy killing rule, imo can only be done by first determing who initated the pvp action, not who took first blood... |
|
Back to top |
|
|
milliorn
Joined: 03 Jun 2006 Posts: 29
|
Posted: Mon Mar 05, 2007 18:17 Post subject: |
|
|
funky: if i sound argumentive, I apologize. im being persistant on this from experience in PvP modules. we all respect you highly for your awesome work with HGLL an SimTools, im along with Scar is just pushing this being that we truely need this form of functionality that is not available in the form we wish to have. |
|
Back to top |
|
|
scarface
Joined: 12 Jun 2005 Posts: 94 Location: Sweden
|
Posted: Mon Mar 05, 2007 22:20 Post subject: |
|
|
FunkySwerve wrote: | milliorn wrote: | ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. |
As with most things, you can make up for engine shortcomings with well-crafted rules (for instance, first damager rather than first attacker). Of course, the plugin is preferable, I'm not naysaying that, I was merely suggesting an alternative for the meantime, but it sounds like you aren't interested. I'm also fairly certain the impossible rated player in your scenario would have to hostile the effy before he'd take an AoO.
Funky |
I'm not nitpicking again, just letting you know but not all AoE spells need you to be hostile to harm you, prehaps with certain rulesets, but as it is we use the normal ruleset and most AoEs do damage players even non hostile (except in no PvP areas of course). |
|
Back to top |
|
|
milliorn
Joined: 03 Jun 2006 Posts: 29
|
Posted: Tue Mar 06, 2007 17:54 Post subject: |
|
|
well, virusman said he was gonna produce a plugin, so I think next step is to see who is going to volunteer some time to hook this plugin into a module |
|
Back to top |
|
|
FunkySwerve
Joined: 02 Jun 2005 Posts: 377
|
Posted: Tue Mar 06, 2007 21:53 Post subject: |
|
|
scarface wrote: | FunkySwerve wrote: | milliorn wrote: | ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. |
As with most things, you can make up for engine shortcomings with well-crafted rules (for instance, first damager rather than first attacker). Of course, the plugin is preferable, I'm not naysaying that, I was merely suggesting an alternative for the meantime, but it sounds like you aren't interested. I'm also fairly certain the impossible rated player in your scenario would have to hostile the effy before he'd take an AoO.
Funky |
I'm not nitpicking again, just letting you know but not all AoE spells need you to be hostile to harm you, prehaps with certain rulesets, but as it is we use the normal ruleset and most AoEs do damage players even non hostile (except in no PvP areas of course). |
You haven't applied PvP fixes?? I coulda sworn you had some posted to the vault, though I don't know if they included AoE fixes. Simple hostile checks will handle that, and you'll have to make those changes (as well as the spellhook edits), and some tweaks to the summoning ai, if you want a complete check, as onattack probably won't handle those. Ondamaged, on the otherhand, probably would, though I'm unsure if appying a damage effect constitutes a 'hit' - guessing yes.
Funky |
|
Back to top |
|
|
scarface
Joined: 12 Jun 2005 Posts: 94 Location: Sweden
|
Posted: Wed Mar 07, 2007 16:02 Post subject: |
|
|
FunkySwerve wrote: | scarface wrote: | FunkySwerve wrote: | milliorn wrote: | ondamage wouldnt settle in a pvp module(arena, hak n slash, etc) cause like mentioned before, a module's team needs to know who initated the pvp, not who damaged first with physical attack or spellcasted. |
As with most things, you can make up for engine shortcomings with well-crafted rules (for instance, first damager rather than first attacker). Of course, the plugin is preferable, I'm not naysaying that, I was merely suggesting an alternative for the meantime, but it sounds like you aren't interested. I'm also fairly certain the impossible rated player in your scenario would have to hostile the effy before he'd take an AoO.
Funky |
I'm not nitpicking again, just letting you know but not all AoE spells need you to be hostile to harm you, prehaps with certain rulesets, but as it is we use the normal ruleset and most AoEs do damage players even non hostile (except in no PvP areas of course). |
You haven't applied PvP fixes?? I coulda sworn you had some posted to the vault, though I don't know if they included AoE fixes. Simple hostile checks will handle that, and you'll have to make those changes (as well as the spellhook edits), and some tweaks to the summoning ai, if you want a complete check, as onattack probably won't handle those. Ondamaged, on the otherhand, probably would, though I'm unsure if appying a damage effect constitutes a 'hit' - guessing yes.
Funky |
Nah, I created fixes for no pvp exploits, not pvp fixes (confused yet? lol), I fixed the kind where you can kill players in no PvP areas, if I were to fix all spells that kill non hostile players in pvp areas, i'd have to modify almost every damage AoE spell in the game, and i'm not patient enough |
|
Back to top |
|
|
virusman
Joined: 30 Jan 2005 Posts: 1020 Location: Russia
|
Posted: Wed Mar 07, 2007 21:59 Post subject: |
|
|
I had some free time today.
First results:
Code: | const int EVENT_SAVE_CHAR = 1;
const int EVENT_PICKPOCKET = 2;
const int EVENT_ATTACK = 3;
void main()
{
SetLocalString(OBJECT_SELF, "NWNX!EVENTS!GETEVENTID", " ");
int nEventType = StringToInt(GetLocalString(OBJECT_SELF, "NWNX!EVENTS!GETEVENTID"));
WriteTimestampedLogEntry("NWNX Event fired: "+IntToString(nEventType)+", '"+GetName(OBJECT_SELF)+"'");
switch(nEventType)
{
case EVENT_PICKPOCKET:
object oPC = OBJECT_SELF;
object oTarget = GetLocalObject(OBJECT_SELF, "NWNX!EVENTS!TARGET");
WriteTimestampedLogEntry(GetName(oPC)+" tried to steal from "+GetName(oTarget));
}
} |
Code: | [Wed Mar 7 22:53:46] NWNX Event fired: 2, 'Test Player'
[Wed Mar 7 22:53:46] Test Player tried to steal from Dummy
[Wed Mar 7 22:53:53] NWNX Event fired: 2, 'Test Player'
[Wed Mar 7 22:53:53] Test Player tried to steal from Dummy |
PickPocket event is hooked. Attack is on the way.
I had to modify NWNX2 core library to hook GetLocalObject as well.
P.S. The first release will be Linux only.
P.P.S. List of possibly "hookable" actions (loc_* are unidentified functions; this list does not include party, DM, inventory functions):
Code: | dd offset pcActMove
dd offset pcActAttack
dd offset pcActUseDoor
dd offset pcActEmote
dd offset pcActExamine
dd offset pcActCastFeat?
dd offset pcActUseSkill
dd offset pcActTalkTo
dd offset pcActUseItem
dd offset pcActToggleMode
dd offset pcActUse
dd offset pcActPickLock
dd offset pcActRest
dd offset pcActLockUnlock?
dd offset glb_8190801
dd offset loc_818F53C
dd offset loc_818F610
dd offset pcActCastSpell
dd offset pcActPossessFamiliar
dd offset loc_818FFA8
dd offset pcActDebugInfo
dd offset pcActMergeItems
dd offset pcActSplitItems
dd offset pcActPause
dd offset loc_81904AC
dd offset loc_8190544
dd offset pcActUnpossessFamiliar
dd offset pcActMoveKeyTurn
dd offset pcActMoveKeyMove
dd offset loc_8190670
dd offset pcActDownloadChar
dd offset pcActSaveGame
dd offset pcActMoveKeyRelease
dd offset pcActAbortAction |
|
|
Back to top |
|
|
FunkySwerve
Joined: 02 Jun 2005 Posts: 377
|
Posted: Wed Mar 07, 2007 22:40 Post subject: |
|
|
While we're at it, can you think of any way to allow an instant item use without a hak? Planning to add some really cool stuff to SIMTools in nwn2, especially with some of the soon-to-be-added commands, but haks in 2 are considerably less problematic since players have to download anyway.
Idea would be to fire off an intant-use item on voice command to pull up a targeting cursor, so that voice commands not sent in tells would get targeted with the targeting cursor. In nwn2 1.06 they have a function for this, but in nwn its haxxors all the way.
Or, since you are the master, what about a function to pull up a targeting gui like in 1.06? Here's the link:
http://oeiprogrammer.blogspot.com/search/label/1.06
Thanks,
Funky |
|
Back to top |
|
|
virusman
Joined: 30 Jan 2005 Posts: 1020 Location: Russia
|
Posted: Wed Mar 07, 2007 22:55 Post subject: |
|
|
FunkySwerve wrote: | While we're at it, can you think of any way to allow an instant item use without a hak? Planning to add some really cool stuff to SIMTools in nwn2, especially with some of the soon-to-be-added commands, but haks in 2 are considerably less problematic since players have to download anyway.
Idea would be to fire off an intant-use item on voice command to pull up a targeting cursor, so that voice commands not sent in tells would get targeted with the targeting cursor. In nwn2 1.06 they have a function for this, but in nwn its haxxors all the way.
Or, since you are the master, what about a function to pull up a targeting gui like in 1.06? Here's the link:
http://oeiprogrammer.blogspot.com/search/label/1.06
Thanks,
Funky | I can't make a trageting GUI, but instant item use must be possible. |
|
Back to top |
|
|
virusman
Joined: 30 Jan 2005 Posts: 1020 Location: Russia
|
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|