Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / AGK Light Question

Author
Message
davidhan
9
Years of Service
User Offline
Joined: 17th Oct 2014
Location:
Posted: 17th Oct 2014 12:54
I am starting my new horse racing game and I have setup a flat grass terrain. My models for now just have 1 basic UV texture and they look pretty good with no lights but I plan to create normal maps and maybe use shaders on them when I get more familiar with this in the future. I used Blender to create them and have a couple questions:

1) What is some basic light setup code I can use in AppGameKit to replicate sunlight across my terrain?

2) If I apply materials in Blender on my object, will they be rendered the same in AppGameKit and if not how is this achieved?

A Nice day.
Matty H
15
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 17th Oct 2014 15:46
When you say 'replicate sunlight', do you mean the way the light hits the object? If yes then this is simply a directional light. If you are talking about shadows then that is more complex.

Van B
Moderator
21
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 17th Oct 2014 16:31
One good thing about a flat terrain is that you can make your own shadows using flat plains, especially with a fixed light source and directional lighting, it should be quite effective and nothing like the trouble or performance cost of a proper shadow calculation.

I would be more worried about animated horses - I guess you could just use several models and switch between them - it'd mostly be a running cycle so that would be doable. AGKv2 has support for animated models, but AGKv1 only has static models, so you would have to come up with your own method.

A normal map shader should be possible, I was actually thinking about making one for AGKv1, just to see how it can be done - I'd probably do it wrong but I am sure it would work.

I am the one who knocks...
SoftMotion3D
AGK Developer
18
Years of Service
User Offline
Joined: 24th Aug 2005
Location: Calgary,Alberta
Posted: 18th Oct 2014 02:43 Edited at: 18th Oct 2014 02:45
Quote: "I would be more worried about animated horses - I guess you could just use several models and switch between them - it'd mostly be a running cycle so that would be doable. AGKv2 has support for animated models, but AGKv1 only has static models, so you would have to come up with your own method."


there is also a 2nd option with agkv1 and works with v2 as well... a limbed animation system and you can check my post about it here:
http://forum.thegamecreators.com/?m=forum_view&t=212261&b=41 or you can easily develop something simular to this.

and it does not do this...
Quote: "I guess you could just use several models and switch between them "


Login to post a reply

Server time is: 2024-04-25 08:36:31
Your offset time is: 2024-04-25 08:36:31