View unanswered posts | View active topics It is currently Thu Dec 26, 2024 4:46 am



Reply to topic  [ 8 posts ] 
 Random Question 
Author Message
User avatar

Joined: Sat Apr 18, 2015 6:17 pm
Posts: 38
Location: Behind you
Reply with quote
Post Random Question
Hi, I'm working on a little mod and I couldn't choose between having a random head, like the ronins or a animated head, so I though, why not both? The problem is that both the ronin script and the animation rely on having multiple frames. So I was wondering if there is a way to randomly choose a head, without using different frames. For instance, a way to choose between head A, head B, or head C, rather than head000, head001 and head002.
Cheers


Sat Sep 10, 2016 5:18 am
Profile

Joined: Fri Sep 10, 2010 1:48 am
Posts: 666
Location: Halifax, Canada
Reply with quote
Post Re: Random Question
I may be mistaken but the only thing I can think of is having several frames for each head - so head one would be frames 1 through 4, head 2 would be 5 through 9, and so on. - and cycling through the head's designated frames with lua.


Sat Sep 10, 2016 5:28 am
Profile
User avatar

Joined: Sat Apr 18, 2015 6:17 pm
Posts: 38
Location: Behind you
Reply with quote
Post Re: Random Question
That actually seems like it could work! The only problem is I suck in lua :( I dont' want to be annoying but would it be too much to ask you if you could write that script if it's not complicated?


Sat Sep 10, 2016 3:26 pm
Profile

Joined: Fri Sep 10, 2010 1:48 am
Posts: 666
Location: Halifax, Canada
Reply with quote
Post Re: Random Question
Maybe? I haven't done anything with CC in quite a while but if no one else bites in the next little while I can give it a gander.


Sat Sep 10, 2016 9:00 pm
Profile
User avatar

Joined: Sat Apr 18, 2015 6:17 pm
Posts: 38
Location: Behind you
Reply with quote
Post Re: Random Question
Thanks a lot! In the meanwhile, I might see what I can do but lua compared to the ini of cortex looks so difficult!


Sat Sep 10, 2016 10:23 pm
Profile

Joined: Fri Sep 10, 2010 1:48 am
Posts: 666
Location: Halifax, Canada
Reply with quote
Post Re: Random Question
If you like learning by reading, there's a whole book on it available online:
https://www.lua.org/pil/contents.html

There's also a similar tutorial on the lua-users wiki:
http://lua-users.org/wiki/LuaDirectory

I've only read specific sections of them on occasion so I don't know how helpful they'll be for you, and the book is for a slightly older version of lua, but they'll probably give you a good handle on things. Otherwise, weegee's scene making tutorials (in the scene making section) and reading through other scripts are how I learned, though staring at code til it makes sense may not be for everyone.
If you do give it a start and get stuck or aren't sure how to do something, I or someone else can always help you out.


Sun Sep 11, 2016 6:53 pm
Profile
User avatar

Joined: Sat Apr 18, 2015 6:17 pm
Posts: 38
Location: Behind you
Reply with quote
Post Re: Random Question
Thanks for helping me learn :) Maybe someday you'll see a brand new mod made by me on the mod release section, who know?


Sat Sep 17, 2016 11:24 pm
Profile

Joined: Fri Sep 10, 2010 1:48 am
Posts: 666
Location: Halifax, Canada
Reply with quote
Post Re: Random Question
Hey cheers, if you have any questions feel free to pm me (or just post em here). I'm more than happy to help explain anything that confuses you. And if you're stuck and do need a lot of help with this request I'm sure I can do something :)


Sat Sep 17, 2016 11:30 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 8 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.137s | 13 Queries | GZIP : Off ]