Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Swimming Script!

Axerax":11h2h577 said:
you should allow the swimming to be activated if Item_ID### Is in inventory, would be like having the Zora Flippers in LoZ:LttP
OR you could make having your iteam turn on the SWIM_SWITCH.

@lvling up...what do you mean by special places? I don't think swimming needs to have a level system......

EDIT: Isn't it Zora's armor?
 
Pretty sure you go to the Zora Falls in Link to the past, talk to the big zora and get the zora flippers. Its the blue tunic in other games though.

When I say level up, meaning you progressivly get better at swimming the more you swim, so eventually swimming would become more convient than walking to get to places, but it has to start out pretty crappy and require some work for the player to obtain.

Can you make the script simply disable dashing/sneaking from Mr.Mo's ABS, because if you do it with sneak/dash, you will keep getting errors to update it.. so it would be like this after a while..
Character_swim_dash_swim_dash_dash_dash_dash... etc

We don't want that, it is like pi, it would go on forever. So if you will change it to when in water and swimming that dash/sneak get disabled.

Another bug I found, when using MrMo's ABS, do you make everything have the "Through" effect, because enemies are coming over the water and attacking. As well you should make another thing that checks if a tile is a wall, disallowing the player to jump out of the water... You could do this using the terrain tags once again. So the player should be the only one able to swim, or even go in water, prevent events from doing this. And set up a wall tag, so the player doesn't jump out of the water onto a wall and get stuck.
 
*drowns in raging torrent of bugs*
....i can fix the wall thing....
EDIT: okay no that doesn't work....maybe ameteur scripter was an over statement. T.T
I wish Chaosg1 would come on msn...

EDIT:: *smacks self* Since there's now touch swimming, all the water tiles are passable...therefore I didn't need to put @through XD...my button script is totally screwed over though...oh well no one liked it. I'll update my first post and remove my button one.
 
What are you having problems with, and you can contact me on MSN at Mikemilius@gmail.com.. my SN is Axerax on AIM as well, feel free to talk with me if you need some help, I do scripting, just not this kind, but I can probly help some.
 
Thnx Axerax. I fixed the trapping thing (can't believe how stupid I was lol).
I have no clue what to do for the suffix conflicts...well it has something to do with @character_name = @character_name.gsub(/_swim/)....something something...lol Chaosg1 put that in for me.
 
I didn't tought of that Suffix error...


But it should take al the Swim Things on the character name...

gsub! takes the "Swim" out of the name... so it should take all Swim things...

but ok I am gonna think in something about that.
 
@Chaosg1 okay thanks
@everyone, how many would like it if the character was animated while in the water when not moving? Sort of like they're treading water?
 
Script updated:
added treading water animation
added diving graphic option
changed water dashing speed
fixed _swim_dash or _dash_swim_dive w/e bugg
 
I added a leveling system. You're almost painfully slow to begin with, but you can get to a decent speed before too long. I think I may have to increase the requirement for the two higher swimming levels. Test it out and let me know what you think!

Edit:...was that considered a double post if I had new but not corrective information?
 
ToriVerly;163527 said:
Script updated:
added treading water animation
added diving graphic option
changed water dashing speed
fixed _swim_dash or _dash_swim_dive w/e bugg

How did you fix the prefix bug?

And I just used sneaking as diving, but I'm curious what it does.
 
Okay technically i didn't really fix anything...but I showed you how to avoid the error by editing the other scripts. It's in the Compatibility part of my post. It's just half a line of code so it's not a huge deal right?
 
I've been trying to convert the ABS to support this now, but I can't figure out where
Code:
and if $game_player.terrain_tag != WATER
goes. If you would show where this goes in a block of code from the script, I think it would help a lot, as well, maybe show where to place the WATER = 1 attribute. I just think a lot of people are gonna get lost by you saying place this where animations begin, the entire script is full of animations, you have to be more specific.
 
You're troublesome T.T (jk)
ummm...graphic change lines looke like this:
Code:
$game_player.character_name =
or
Code:
@character_name =
In Mr.Mo's ABS it's under
Code:
def dash_update
after all the junk after the '=' at the end of the same line put
Code:
and if $game_player.terrain_tag != WATER
and I said for
Code:
WATER = 1
put it at the top. Very top. Above everything else in that page. Go to line 1, hit enter, and put it
Code:
WATER = 1
there.(btw this is the script called Mr.Mo's ABS V4.5. I know his demo has a lot of scripts)

EDIT: I have a way to fix the bug but then you end up running on water.
EDIT: I can make it work if you have a _dash_swim and _sneak_swim sprite
EDIT:: Is it just me, or does Mr.Mo's ABS ask for _sneak_sneak if you hold the button after you run out? I even cut out my script...I think it does...and _dash_dash too...some one please let me know if you get this also...that means it's not my fault :D
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top