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
RandInt ?!
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#1
RandInt ?!

I am trying to create some "big landscapes" where you usually play on, so I am not gonna use planes this time.
but yeah, I made a big big Landscape, I'm really happy that I made something like this,
I did a little paint on it, like red lava rock kinda things, some "path" etc, I painted it with around 5 images.
Now the real problem.
Exporting issue, I export it as a .obj
and then rescale it etc, but then, I have to apply new textures to it.
and that is not possible, since that thing is 1 mesh object, and I used around 5 images.
Is there a way to create a "Uv" kinda map from all the paint layers you painted on the object?!
I have a friend, who's a really good animator, and sculptor, but he didn't know aobut this export thing either.

Btw, is there a possibility, to automatic, create a body to the object you make, in maya?
I mean.. you know how difficult it would be for me, If I had to add body, to my landscape? xD I'm sure I have to use around 8 million bodies then lol jk.


Btw, A little side question, how does RandInt work?!
what I actually want is 3 objects, what all the 3 objects spawns on like.. .5 diffirent locations.
I searched up in the engine scripts, but I really didn't understand anything Sad
(This post was last modified: 07-06-2015, 08:42 PM by Amnesiaplayer.)
07-05-2015, 08:01 PM
Find
Traggey Offline
is mildly amused

Posts: 3,257
Threads: 74
Joined: Feb 2012
Reputation: 185
#2
RE: MudBox Export Issue

First of, no, there is no way of creating landscape masks for textures in HPL, you could paint the entire thing with a bunch of textures and bake them down into one texture, but that would result in terrible texture resolution, so when it comes to landscapes in HPL using only one material is the best way to go.

Also no, there is no way of creating a body for it in maya.
(This post was last modified: 07-05-2015, 09:37 PM by Traggey.)
07-05-2015, 09:35 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#3
RE: MudBox Export Issue

But do you know how I can turn all of these paint "layers" into one, uv map, so I can apply it in maya, and then finally export it to hpl Tongue
Thanks Smile
Edit: Wait, if I copy the landscape, and paste it and put it 0.0001 lower, then the orginal, and add another material, and then in hpl2 engine, can't I turn that material in body? Sad
Wouldn't that be AWESOME!
(This post was last modified: 07-05-2015, 09:48 PM by Amnesiaplayer.)
07-05-2015, 09:46 PM
Find
Traggey Offline
is mildly amused

Posts: 3,257
Threads: 74
Joined: Feb 2012
Reputation: 185
#4
RE: MudBox Export Issue

Yes, you preform a diffuse channel bake from the painted mesh to an indentical copy with a proper squared out UV.

However as I stated before, it will look terrible unless you use HUGE texture sizes, which simply will not work. So that is not a method you should even consider trying.

And no, you can not do that, you'll need to add the body manualy.
(This post was last modified: 07-05-2015, 10:00 PM by Traggey.)
07-05-2015, 10:00 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#5
RE: MudBox Export Issue

Thanks, I think I have an idea for this, I can just simply make the landscape, and then add a texture for the whole thing, and then select some faces, and make that "Seperate" and use another textures for the "path"
Btw, do you know aboutthe RandInt??
07-05-2015, 10:04 PM
Find
Traggey Offline
is mildly amused

Posts: 3,257
Threads: 74
Joined: Feb 2012
Reputation: 185
#6
RE: MudBox Export Issue

I have no idea what that is, no.

And yes, you could do that, however keep in mind that this would cause terrible looking edges between your different materials, sharp edges etc etc, which is not pleasant to look at.
07-05-2015, 10:06 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#7
RE: MudBox Export Issue

(07-05-2015, 10:06 PM)Traggey Wrote: I have no idea what that is, no.

And yes, you could do that, however keep in mind that this would cause terrible looking edges between your different materials, sharp edges etc etc, which is not pleasant to look at.

Yes, I am going to try a lot of diffirent things, hoping for the best Tongue
edit: Never mind. I give up.
tried so many things, it won't result good.
Now I have to stay with planes Sad
(This post was last modified: 07-05-2015, 11:06 PM by Amnesiaplayer.)
07-05-2015, 10:15 PM
Find
Daemian Offline
Posting Freak

Posts: 1,129
Threads: 42
Joined: Dec 2012
Reputation: 49
#8
RE: MudBox Export Issue

PHP Code: (Select All)
int RandInt(int alMinint alMax); 
It generates a random number between alMin and alMax

Quote:int n = RandInt(0,10);
n gets a number between 0 and 10.

You can use it for many things, like to obtain a chance to do something.

Quote:int n = RandInt(0,10);
if (n==0) { GameOver = false; }

07-06-2015, 01:38 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#9
RE: MudBox Export Issue

(07-06-2015, 01:38 PM)Daemian Wrote:
PHP Code: (Select All)
int RandInt(int alMinint alMax); 
It generates a random number between alMin and alMax

Quote:int n = RandInt(0,10);
n gets a number between 0 and 10.

You can use it for many things, like to obtain a chance to do something.

Quote:int n = RandInt(0,10);
if (n==0) { GameOver = false; }

Oh thanks,
but if I want like, you spawn in your house and there are 3 pieces, parts.
and there are 2 locations of all the 3 parts, can I make this happen with randint?!
Like part 1, 50% at loc1, 50% at loc2, part 2 50%loc3, 50%loc4, and part 3 50% loc5, and 50%loc6 etc...
Because in the map where I need that, there are some things you have to do, if you die, you have to start over, so it would make it better if the chances are random, or otherwise it would be too easy for them to beat the parts they already did..
07-06-2015, 01:59 PM
Find
Daemian Offline
Posting Freak

Posts: 1,129
Threads: 42
Joined: Dec 2012
Reputation: 49
#10
RE: RandInt ?!

Having: Area1, Area2, Area3... 5:

PHP Code: (Select All)
int n RandInt(1,5);
TeleportPlayer"Area"+); 

That basic idea can be applied to similar situations like you mention.

Note: To teleport the player, the area must be a StartLocation type.

Or use SetPlayerPos

(This post was last modified: 07-07-2015, 08:30 PM by Daemian.)
07-07-2015, 08:29 PM
Find




Users browsing this thread: 1 Guest(s)