Total Miner Forums

Total Miner => Bug Reports [PC Beta] => Topic started by: empire 3001 on June 06, 2018, 09:39:48 PM

Title: Script bugs
Post by: empire 3001 on June 06, 2018, 09:39:48 PM
Bug found on the waiting command

        Example

setblock [dirt] [x,y,z]
wait [3000]
if
is block [x,y,z] [dirt] [true]
then
commit
endif

it wont spawn the block untill the 3 secs and i doubled checked to see if it was before the command
well the block is there but its invisible.
Title: Re: Script bugs
Post by: The Gold Knight on June 07, 2018, 02:56:00 AM
Bug found on the waiting command

        Example

setblock [dirt] [x,y,z]
wait [3000]
if
is block [x,y,z] [dirt] [true]
then
commit
endif

it wont spawn the block untill the 3 secs and i doubled checked to see if it was before the command
well the block is there but its invisible.
That's because the commit command is used to force a graphics refresh. Your script is only making sure the block is visible after the 3 second wait.
Title: Re: Script bugs
Post by: empire 3001 on June 07, 2018, 03:20:26 PM
well that was just an example I didn't use commit on my script, my script is to long to post so I just wrote another one.

the glitch is there ive biuld it on the xbox 360 before and it worked fine on that but glitchey on the pc.
Title: Re: Script bugs
Post by: The Gold Knight on June 07, 2018, 07:24:44 PM
well that was just an example I didn't use commit on my script, my script is to long to post so I just wrote another one.

the glitch is there ive biuld it on the xbox 360 before and it worked fine on that but glitchey on the pc.
If you don't post the actual script we won't be able to tell you if it's an actual bug or not. If you don't use commit on your actual script, you probably should.
Title: Re: Script bugs
Post by: empire 3001 on June 09, 2018, 12:24:56 AM
My script is about 150 lines but I shortened it to 15 for an example
if
is random [100,100]
then
setblock [rel:x,y,z] [dirt]
endif
if
isblock [rel:x,y,z] [dirt] [true]
then
inventory [actor] [add] [goldpieces] [100]
notify [100gp] [local] [9,9,9]
setpower [rel:x,y,z] [on]
wait [3000]
setpower [rel:x,y,z] [off]
endif
"Optional" commit

the block should appear but is invisable somtimes it works right away sometimes it doesnt should glitch within 5 trys.
Title: Re: Script bugs
Post by: empire 3001 on June 12, 2018, 02:11:56 PM
Bug found on the waiting command

        Example

setblock [dirt] [x,y,z]
wait [3000]
if
is block [x,y,z] [dirt] [true]
then
commit
endif

it wont spawn the block untill the 3 secs and i doubled checked to see if it was before the command
well the block is there but its invisible.
That's because the commit command is used to force a graphics refresh. Your script is only making sure the block is visible after the 3 second wait.
Yup sorry no bug lol its been a while since I script... Thanks