Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Some complex issue (SOLVED)
TheGreatCthulhu Offline
Member

Posts: 213
Threads: 10
Joined: Oct 2010
Reputation: 32
#5
RE: Some complex issue

That shouldn't cause the issue; the RandInt function returns an integer, so functionally the two variants of the code should be equivalent - if not, then it's a bug in the script engine (but I don't think that is the case). Try Mudbill's suggestion anyway, just in case.

After that - if you are sure that the lines of code you quoted are the ones that are causing the problem, you can pinpoint the source like this: first comment out just the "PlaySoundAtEntity" part (just place // in front), and see if the game crashes or not. If it does, than that line is the problem. If not, un-comment it, and comment out the "if(GetLocalVarInt(sEvent) == 12) return;" part, then run, and if the game doesn't crash, that line was the problem.

That said, that particular line looks suspicious to me, because of this:
PHP Code: (Select All)
//Reached final step, no need for further guardian sounds
    
if(GetLocalVarInt(sEvent) == 12) return;
    
    
//Configurables
    
string sEvent asTimer//Sets the timer name to the variable name 

Note that sEvent is declared after it is used in the previous line of code. That shouldn't even compile.
The "string sEvent = asTimer;" part should come before the call to GetLocalVarInt.
(This post was last modified: 08-16-2014, 07:26 PM by TheGreatCthulhu.)
08-16-2014, 07:25 PM
Find


Messages In This Thread
Some complex issue (SOLVED) - by Neelke - 08-16-2014, 01:19 AM
RE: Some complex issue - by FlawlessHappiness - 08-16-2014, 02:32 AM
RE: Some complex issue - by Neelke - 08-16-2014, 12:07 PM
RE: Some complex issue - by Mudbill - 08-16-2014, 03:44 PM
RE: Some complex issue - by TheGreatCthulhu - 08-16-2014, 07:25 PM
RE: Some complex issue - by Neelke - 08-16-2014, 10:41 PM
RE: Some complex issue (SOLVED) - by Neelke - 08-17-2014, 02:16 PM



Users browsing this thread: 1 Guest(s)