Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Michael Chan
Newbie


Joined: 02 Apr 2004
Posts: 5
Location: USA

PostPosted: Fri Apr 02, 2004 7:24 am   

Access Violation - c0000005
 
I get the following error:

The application, E:zMUDZmud.exe, generated an application error The error occurred on 04/02/2004 @ 00:53:44.546 The exception generated was c0000005 at address 004D94AC (Zmud).

I got it while I was running the following script:

#CLASS {AutoRoll}
#TRIGGER {^Use this body} {n;#AD rollcounter 1}
#TRIGGER {^{Good|Fair}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}} {#T- AutoRoll;y;#SAY @rollcounter;#ALARM {*:*1:*} {z}}
#CLASS 0
Reply with quote
nexela
Wizard


Joined: 15 Jan 2002
Posts: 1644
Location: USA

PostPosted: Fri Apr 02, 2004 7:57 am   
 
I think it comes from disabling a class with commands left to be exectuted restructre it like this and let us know if that works

#CLASS {AutoRoll}
#TRIGGER {^{Good|Fair}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}} {#T- RollAgain;y;#SAY @rollcounter;#ALARM {*:*1:*} {z;#T- AutoRoll}}
#CLASS 0
#CLASS {AutoRoll|Rollagain}
#TRIGGER {^Use this body} {n;#AD rollcounter 1}
#CLASS 0
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Fri Apr 02, 2004 6:01 pm   
 
Sorry to disagree, nexela, but I frequently use #T- to disable either the class or the trigger itself with additional commands after that. This is a deliberate choice on my part to ensure that the trigger (or class) is disabled before it can see the results of those additional commands. It's never caused any problems that I'm aware of.

Here, the purpose is to make sure that the class is disabled soon enough to prevent the first trigger from sending an 'n' and placement of the #T- command may make a difference. However, the autoroller could be rewritten so the #T- isn't necessary.

I don't see anything in the script which should cause problems. On the other hand, I've noticed that "Access Violation" is a frequent topic on the current version and nobody really seems to have a good answer to what's causing it. Sorry I can't be of more help, Michael.

#VAR fg 0
#CLASS {AutoRoll}
#TRIGGER {^Use this body} {#IF (@fg > 0) {} {n;#AD rollcounter 1}} {} {prompt|nocr}
#TRIGGER {^{Good|Fair}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}} {#VAR fg 1;y;#SAY @rollcounter;#ALARM {*:*1:*} {z}}
#CLASS 0

EDIT: It seems likely that the first trigger will need to be a Prompt trigger. I added the options for that.
Reply with quote
nexela
Wizard


Joined: 15 Jan 2002
Posts: 1644
Location: USA

PostPosted: Fri Apr 02, 2004 11:37 pm   
 
Hehe see I am wrong rarely[tiny]sometimes[/tiny][verytiny]most of the time[/verytiny][teeny_weenie]almost all the time[/teeny_weenie]
Reply with quote
Michael Chan
Newbie


Joined: 02 Apr 2004
Posts: 5
Location: USA

PostPosted: Sat Apr 03, 2004 12:38 pm   
 
Well, apparently there's a new version of zMUD out, 7.05.

I'll replace the current script with your listed script, LightBulb.

Will report back if anything changes :)
Reply with quote
Michael Chan
Newbie


Joined: 02 Apr 2004
Posts: 5
Location: USA

PostPosted: Sat Apr 03, 2004 12:55 pm   
 
Hmm, interestingly enough, the modified script you posted doesn't seem to work.

If it would help, the character strings when rolling appears as:

Str Int Wis Dex Agi Con Cha Wil Voi Per App
Low Aver Aver Fair Good Aver Low Good Aver Fair Aver
The professions that your race can belong to are:
A) Fighter: B) Cleric:* C) Bard:NA(R)
D) Thief:NA(A) E) Barbarian:NA(R) F) Forester:NA(R)
G) RuneMage:* H) Psion:*
Recommended profession : Psion
Use this body ? Y,n
Reply with quote
Michael Chan
Newbie


Joined: 02 Apr 2004
Posts: 5
Location: USA

PostPosted: Sat Apr 03, 2004 12:57 pm   
 
Er.. forum seems to format it oddly.

Between each statistic roll there are 2 spaces. Though i'm pretty sure you knew that from reading the initial script. Me? I have absolutely no knowledge of zMUD's scripting methods :(
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Sat Apr 03, 2004 5:27 pm   
 
Yes, the %s accounts for the spaces. I only changed two things from your original script.
1. I used a variable to control the trigger instead of #T-
2. I changed it from a Newline to a Prompt trigger

If it was working before, and isn't working now, it's probably because of the second change. Just remove the options.

#VAR fg 0
#CLASS {AutoRoll}
#TRIGGER {^Use this body} {#IF (@fg > 0) {} {n;#AD rollcounter 1}}
#TRIGGER {^{Good|Fair}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}%s{Fair|Good}} {#VAR fg 1;y;#SAY @rollcounter;#ALARM {*:*1:*} {z}}
#CLASS 0

NOTE: Make sure your class options don't include Set as Default when executing.
Reply with quote
Michael Chan
Newbie


Joined: 02 Apr 2004
Posts: 5
Location: USA

PostPosted: Sat Apr 03, 2004 11:41 pm   
 
Used your again modified script (thanks a heck of a lot by the way)... made sure the Set as default wasn't checked.

The trigger is somewhat working. It at least can parse the rolls but even if I set it to accept any possible roll, it rejects it (sends N instead of Y).
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
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

© 2009 Zugg Software. Hosted by Wolfpaw.net