Register  |  FAQ  |  Search  |  Memberlist  |  Usergroups  |  Log in 
Reply to topic
 Shooting Objects 
nigec


Joined: 04 Jul 2007
Posts: 212
Reply with quote
my little passage scene has progressed a bit and now has 1st person shooter ie, bullets, gun sound etc.. any chance of a tutorial to shoot an object?
I had a go with tank girl from TS and using empire of Quin scripts but bullets and the player walk through her and nothing works basiclly lol
View user's profile Send private message
  
Vincent


Joined: 25 Dec 2006
Posts: 296
Reply with quote
The player should not walk through SkinMeshs, please first place the model on the origin in trueSpace, then export it.

For bullet, you need:

1. Define a Script Variable for the SkinMesh, the variable name should be same with mesh name (assume the name is 'girl')
2. Add a onBulletHit() function to the variable:

Code:
girl.onBulletHit = function( hitpos, bulletpower )
   -- do something when a bullet hitting
end



when a bullet hitting a SkinMesh, the codes in handbullet.lua will call the onBulletHit function.

also see tiger.lua.
View user's profile Send private message
  
nigec


Joined: 04 Jul 2007
Posts: 212
Reply with quote
Thanks Very Happy
Once the Cubic demo is finished I plan to do a 1st person shooter, probably something like Beachhead but i'd love to do something like Battlefield 1942
View user's profile Send private message
  
Vincent


Joined: 25 Dec 2006
Posts: 296
Reply with quote
Great!
View user's profile Send private message
  
nigec


Joined: 04 Jul 2007
Posts: 212
Reply with quote
Vincent wrote:
Great!


not when i start asking dumb questions again lol
View user's profile Send private message
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 vote in polls in this forum
All times are GMT  
Page 1 of 1  

  
  
 Reply to topic