WASP3D Forum Go to: www.wasp3d.com
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
View
Go to last post Go to first unread
Offline Umair Ahmed  
#1 Posted : 28 January 2014 15:13:02(UTC)
Umair Ahmed

Rank: Member

Groups: Registered
Posts: 11
Man
Pakistan

Dear WASP3D & Users,
I beg your pardon if this isn't the right place to post this topic in which I require help.

While making Countdown(Time) I am experiencing an issue where I am unable to fix the timer to end at my desired/required time.

For instance in Drone Designer, taking 3D Text and changing its parameters to Countdown(Time) and defining the format (For Eg: 12 hours, 56 mins & 40 secs (hh:mm:ss)) and saving as template, while playing on Sting Server it displays the correct desired countdown. But when stopping and closing the file in Sting Client and reloading the template after one hour, the countdown time resets to 12 hours, 56 mins & 40 secs instead of showing 11 hours, 56 mins & 40 secs which is obvious.

Is there someway where I can set any Counter/Format/Combuilder option to 'For Eg: 12am midnight', play the file, stop and reload it after one hour, then it will show me the updated remaining countdown time without any timely manual changes in Drone Designer.

Awaiting response of WASP3D Team and Users.

Thank You,
Regards,
UMAIR AHMED
AAJ NEWS, PAKISTAN
Offline Sreenath  
#2 Posted : 29 January 2014 05:56:41(UTC)
Sreenath

Rank: Advanced Member

Groups: Adv.Moderators
Posts: 4
Man
India
Location: Noida

Hi Umair Ahmed,


I am a WASP3D Team Member.

I read the topic you wrote about the countdown timer issue.The countdown timer you used is not suitable for your requirement.Instead you can make a countdown timer through code in the scene.

Thanks & Regards,

SREENATH K N
WASP3D | Beehive Systems
Offline Umair Ahmed  
#3 Posted : 29 January 2014 09:20:49(UTC)
Umair Ahmed

Rank: Member

Groups: Registered
Posts: 11
Man
Pakistan

Dear Sreenath,
Thank You for your quick reply. If you could please elaborate and explain more on how to make countdown timer through code in the scene?

Thanks,

Regards,
UMAIR AHMED
AAJ NEWS, PAKISTAN
Offline Sreenath  
#4 Posted : 29 January 2014 10:44:19(UTC)
Sreenath

Rank: Advanced Member

Groups: Adv.Moderators
Posts: 4
Man
India
Location: Noida

Hi Umair Ahmed,

As you said i am just sending you a brief description and a example scene to you.

Notes for making timer is below:

Timer Making Notes:

1.This is a count up timer done through code.

2.In this, the updation of time is done through an event called Pre Render event.

3.The event raises when scene become render and it comes 25 (frame rate of the scene) times in a second.

Steps:

1.Create the scene on which you want to implement Timer.

2.Just put a 3D Text on the scene on which the time is displayed.

3.Now just click the scene editor tab.

4.On this you can see the AttachSceneHandlerEvents method DetachSceneHandlerEvents.

in AttachSceneHandlerEvents

this.m_pEngineWrppr.m_evtEWEnginPreRenderInfo+=OnPrerender; inside try

in DetachSceneHandlerEvents

this.m_pEngineWrppr.m_evtEWEnginPreRenderInfo -=OnPrerender; inside try

You have to make a method called OnPrerender,this is the method on which the pre render event is attached;

Now increment the time inside this Method as per the requirement.

If you need count up timer increment the time by maintaining values inside the method.

If you need Count down timer you have to decrement the time values.

Make a local variable inside the scene and wire it with the 3DText.

After calculating values inside the pre render event put this values to the local variable

eg:this.LocalVariable.String_1="00:00:00"; here String_1 is the local variable
File Attachment(s):
CounterTimerExample.arc (660kb) downloaded 81 time(s).

You cannot view/download attachments. Try to login or register.
Offline Sreenath  
#5 Posted : 29 January 2014 10:56:35(UTC)
Sreenath

Rank: Advanced Member

Groups: Adv.Moderators
Posts: 4
Man
India
Location: Noida

Hi Umair Ahmed,

On the countdown timer you made the 3DText or Timer is saved with a value 12:56:40.Thus when you open the scene it gets the start value as 12:56:40.It does not get the value of where it is stopped in previous play.

The scene that i given to you post the start time and end time.So you can change the value as you desired.


Thanks & Regards,

SREENATH K N
WASP3D | Beehive Systems

Offline Umair Ahmed  
#6 Posted : 30 January 2014 07:02:11(UTC)
Umair Ahmed

Rank: Member

Groups: Registered
Posts: 11
Man
Pakistan

My apologies Sreenath, I forgot to mention I am using WASP3D 2009 version where I am not provided any Scene Editor Tab. If i could find a solution for WASP3D 2009 I shall be very thankful to you.

Sorry once again..

Thanks
Regards,
UMAIR AHMED
AAJ NEWS, PAKISTAN
Offline Sreenath  
#7 Posted : 30 January 2014 09:28:13(UTC)
Sreenath

Rank: Advanced Member

Groups: Adv.Moderators
Posts: 4
Man
India
Location: Noida

Hi Umair Ahmed,


Me too requesting apology on this matter because this forum is only for community edition.If you need more support from WASP Team please contact in [email protected].


Thanks & Regards,

SREENATH K N
WASP3D | Beehive Systems
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.
Copyright © 2024 Beehive Systems Pvt. Ltd, All Rights Reserved.