Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 01-19-2011, 04:28 AM
MrOmega MrOmega is offline
One More Time
MrOmega's Avatar
Join Date: Aug 2010
Location: TN, USA
Posts: 631
MrOmega is an unknown quantity at this point
Send a message via AIM to MrOmega Send a message via MSN to MrOmega Send a message via Yahoo to MrOmega
Something as simple as a Bomb

Well, getting down to the nitty gritty now and I'm trying to completely recreate the bomb. I have run into a few snags and need some input/guidance. So all clientside I can get this to work flawlessly for the current player. But it looks horrible and choppy for other players and other players cant pick up the bomb after the current player has dropped it. So, I've tried interpolation with it and that has fixed the choppiness of it mostly. (except in cases of extreme lag) My issue is the whole throwing and landing part. I can through it serverside and it looks choppy but how could I go about making it smooth for all at the same time. The bomb is basically an NPC using a gani. Should I change this method or what?
__________________
Time is the fire in which we burn...
Up, Up, Down, Down, Left, Right, Left, Right, B, A, Select, Start! Now I got 99 LIVES!!!
Reply With Quote
  #2  
Old 01-19-2011, 04:30 AM
Knux Knux is offline
WEREDUCK
Knux's Avatar
Join Date: Aug 2007
Posts: 241
Knux will become famous soon enough
I don't think the bomb NPC is just using a gani sir :O
__________________

Supporter of G2K1 revision. Even though it never will be what it was..
Reply With Quote
  #3  
Old 01-19-2011, 04:33 AM
MrOmega MrOmega is offline
One More Time
MrOmega's Avatar
Join Date: Aug 2010
Location: TN, USA
Posts: 631
MrOmega is an unknown quantity at this point
Send a message via AIM to MrOmega Send a message via MSN to MrOmega Send a message via Yahoo to MrOmega
Quote:
Originally Posted by Knux View Post
I don't think the bomb NPC is just using a gani sir :O
Well theres code behind it. I mean for displaying it, it uses a gani. Gani lasts for five seconds and then thats when I do my custom explosion as well.
__________________
Time is the fire in which we burn...
Up, Up, Down, Down, Left, Right, Left, Right, B, A, Select, Start! Now I got 99 LIVES!!!
Reply With Quote
  #4  
Old 01-19-2011, 04:39 AM
Knux Knux is offline
WEREDUCK
Knux's Avatar
Join Date: Aug 2007
Posts: 241
Knux will become famous soon enough
Yes but it's setting a gani like pickup or whatever the gani is. The actual bomb itself is placed with placeexplosion, or whatever isn't it? I dunno I haven't scripted since GS1 and don't remember any of it
__________________

Supporter of G2K1 revision. Even though it never will be what it was..
Reply With Quote
  #5  
Old 01-19-2011, 04:44 AM
MrOmega MrOmega is offline
One More Time
MrOmega's Avatar
Join Date: Aug 2010
Location: TN, USA
Posts: 631
MrOmega is an unknown quantity at this point
Send a message via AIM to MrOmega Send a message via MSN to MrOmega Send a message via Yahoo to MrOmega
I'm not using putbomb or any of that, I'm doing it from scratch.
__________________
Time is the fire in which we burn...
Up, Up, Down, Down, Left, Right, Left, Right, B, A, Select, Start! Now I got 99 LIVES!!!
Reply With Quote
  #6  
Old 01-19-2011, 04:45 AM
Lance Lance is offline
dark overlord
Lance's Avatar
Join Date: Sep 2003
Location: Space Jam Mountain
Posts: 5,072
Lance is on a distinguished road
Use a projectile (shoot command) to throw it. Have the projectile handling code place a bomb NPC of your design (with putnpc2) at the destination.
Reply With Quote
  #7  
Old 01-19-2011, 04:57 AM
Knux Knux is offline
WEREDUCK
Knux's Avatar
Join Date: Aug 2007
Posts: 241
Knux will become famous soon enough
Quote:
Originally Posted by MrOmega View Post
I'm not using putbomb or any of that, I'm doing it from scratch.
I understand that. But isn't bomb like predefined or whatever?
__________________

Supporter of G2K1 revision. Even though it never will be what it was..
Reply With Quote
  #8  
Old 01-19-2011, 06:05 AM
MrOmega MrOmega is offline
One More Time
MrOmega's Avatar
Join Date: Aug 2010
Location: TN, USA
Posts: 631
MrOmega is an unknown quantity at this point
Send a message via AIM to MrOmega Send a message via MSN to MrOmega Send a message via Yahoo to MrOmega
Quote:
Originally Posted by Knux View Post
I understand that. But isn't bomb like predefined or whatever?
Yes but I don't want the predefined one. I'm going for better functionality and customization.

@Lance - how would I read what step that gani is at and how would I make it continue from that step in the shoot, as well as if the bomb needs to explode while in mid air?
__________________
Time is the fire in which we burn...
Up, Up, Down, Down, Left, Right, Left, Right, B, A, Select, Start! Now I got 99 LIVES!!!
Reply With Quote
  #9  
Old 01-19-2011, 06:45 AM
MrAnonymous_P2P MrAnonymous_P2P is offline
Retired Oldbie
MrAnonymous_P2P's Avatar
Join Date: Oct 2006
Location: Cambodia
Posts: 722
MrAnonymous_P2P is an unknown quantity at this point
I believe if you put the lime in the coconut, then mix it all up?


That might work.
Reply With Quote
  #10  
Old 01-19-2011, 07:12 AM
Lance Lance is offline
dark overlord
Lance's Avatar
Join Date: Sep 2003
Location: Space Jam Mountain
Posts: 5,072
Lance is on a distinguished road
Quote:
Originally Posted by MrOmega View Post
@Lance - how would I read what step that gani is at
npc.anistep, if I recall correctly.

Quote:
and how would I make it continue from that step in the shoot,
By passing the step as a shoot parameter (see setshootparams).

Quote:
as well as if the bomb needs to explode while in mid air?
You'd have to see what options are available for accessing projectiles-in-motion. I've never dabbled with that personally so I'm not sure what the limitations are or just how inelegant it might be.
Reply With Quote
  #11  
Old 01-19-2011, 08:02 AM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Quote:
Originally Posted by Lance View Post
You'd have to see what options are available for accessing projectiles-in-motion. I've never dabbled with that personally so I'm not sure what the limitations are or just how inelegant it might be.
There aren't really any. If it needs to be able to explode mid-air, I would think your best bet is to use move (or script your own version that handles the NPC's Z) so it appears smooth on clientside. You could still blow it up mid-air if you destroy the NPC and then place the explosion (using another putnpc2, a showani, or however you do it).
__________________
Reply With Quote
  #12  
Old 01-19-2011, 08:07 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
You could POSSIBLY hack a method. Give the bomb projectile a power and zangle based how the time left when thrown. Make a bomb with a short fuse land faster than a bomb with a longer fuse. Then do the Z method yourself(since you'd be giving the bomb a projection based on fuse, and not the actual throw).
Reply With Quote
  #13  
Old 01-19-2011, 11:02 AM
Switch Switch is offline
o.o
Switch's Avatar
Join Date: Jan 2007
Location: Philadelphia
Posts: 3,038
Switch has a spectacular aura about
Send a message via MSN to Switch
Quote:
Originally Posted by cbk1994 View Post
There aren't really any.
Which is why I made this and never used it.

http://forums.graalonline.com/forums...hp?t=134259144
__________________
Oh squiggly line in my eye fluid. I see you lurking there on the peripheral of my vision.
But when I try to look at you, you scurry away.
Are you shy, squiggly line?
Why only when I ignore you, do you return to the center of my eye?
Oh, squiggly line, it's alright, you are forgiven.
Reply With Quote
  #14  
Old 01-19-2011, 01:12 PM
Knux Knux is offline
WEREDUCK
Knux's Avatar
Join Date: Aug 2007
Posts: 241
Knux will become famous soon enough
Quote:
Originally Posted by MrOmega View Post
Yes but I don't want the predefined one. I'm going for better functionality and customization.

@Lance - how would I read what step that gani is at and how would I make it continue from that step in the shoot, as well as if the bomb needs to explode while in mid air?
Are you going to make a bomb for scratch, or get a walk-thru on here?
__________________

Supporter of G2K1 revision. Even though it never will be what it was..
Reply With Quote
  #15  
Old 01-19-2011, 03:37 PM
MrOmega MrOmega is offline
One More Time
MrOmega's Avatar
Join Date: Aug 2010
Location: TN, USA
Posts: 631
MrOmega is an unknown quantity at this point
Send a message via AIM to MrOmega Send a message via MSN to MrOmega Send a message via Yahoo to MrOmega
Quote:
Originally Posted by Knux View Post
Are you going to make a bomb for scratch, or get a walk-thru on here?
I'm getting help and knowledge of the best practical way to do this. There's nothing wrong with that.

Update : So how do I go about reading the current anistep of a shoot gani? I could catch this gani step while the shoot is in mid air and put the explosion that way, but how would I as well stop a shoot gani while in mid-air? Also how would I make a gani play entirely from a certain anistep?
__________________
Time is the fire in which we burn...
Up, Up, Down, Down, Left, Right, Left, Right, B, A, Select, Start! Now I got 99 LIVES!!!

Last edited by MrOmega; 01-19-2011 at 05:01 PM..
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 10:12 AM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
Copyright (C) 1998-2008 Linux cyberjoueurs All Rights Reserved.