SRB2 Message Board  

Go Back   SRB2 Message Board > Archived > SRB2 Forum Archives > Bug Reports (2.1.X) > Bug Report Cleanup

 
 
Thread Tools Search this Thread
Old 01-17-2017   #1
Katmint
Default 2.1.17 broke my touchspecial hook

see attachment for error, the line in questions that errors is:
Code:
addHook("TouchSpecial", AmyJump, i)
this worked fine in 2.1.16
Attached Thumbnails
Click image for larger version

Name:	srb20000.png
Views:	101
Size:	4.1 KB
ID:	9488  

Last edited by Monster Iestyn; 01-17-2017 at 02:39 AM.
Katmint is offline  
Old 01-17-2017   #2
Monster Iestyn
Friendly Neighbour-Hood
Moderator
 
Monster Iestyn's Avatar
Default

By any chance does the script use "for i = 0,#mobjinfo"? If so, #mobjinfo should be #mobjinfo-1 instead, and this is really a fault on the part of the script.
Monster Iestyn is offline  
Old 01-17-2017   #3
Katmint
Default

thanks that fixed it

ignore this then
Katmint is offline  
Old 01-17-2017   #4
Monster Iestyn
Friendly Neighbour-Hood
Moderator
 
Monster Iestyn's Avatar
Default

No worries, this is probably useful info for other modders who made the same error: since 2.1.17 addHook now has error checking with regards valid mobj type indexes just as with mobjinfo[], and #mobjinfo isn't a valid mobj type number as you probably should be aware.
Monster Iestyn is offline  
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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


All times are GMT. The time now is 10:28 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.