Monday, May 17, 2021

Time_of_Day

 I've changed the code slightly on my Back and Forth with

Hump gamestate. Below, I'm now keeping 'Hello!' visible,

and I've added a back to the first gamestate key without the

timer event. Here is the result:




Yes, I can go b and f between menu and game. But once I've changed

the value of text from 'Hello!', there is no going back to it with either key.

In short, once a change has kicked in, that's it!!


                                       


👧Been wondering if I could use Hump to create choice for things like time-of-day

backgrounds on a game...


That's today's problem!


                                                           *     *     *

Of course, this can be done and produces a clean switch. Below, on the Mario, 

Character4 code:





Only problem, one opens by default on a grey sky and can only switch to nighttime;

but that's my ineptitude.

And there is a lot of fun to be had with the different tweening models:


https://hump.readthedocs.io/en/latest/timer.html


                                                *     *     *

Was asked about how to define color:





So, for a custom color, one uses an array; whereas just using the interface,

one fills in a parenthesis for rgbo like for other values.

No comments: