Jump to content
A 2021 backup has been restored. Forums are closed and work in progress. Join our Discord server for more updates! ×
SoaH City Message Board

BOB_ROX

Members
  • Posts

    124
  • Joined

  • Last visited

About BOB_ROX

  • Birthday 04/28/1995

Profile Information

  • Fan Gaming Specialty
    Level, Sprite, Boss and Character Design.

BOB_ROX's Achievements

Newbie

Newbie (1/14)

1

Reputation

  1. Hello, I havent been on here for awhile now. But I got some trouble with my game, Or so far with a game. Im using the genesis engine, And Im having trouble with homing attack and targetting system, Now I had some help with getting the homing and jump dash and all. But when Sonic goes towards the target he keeps going towards the right. Always. I was wondering if I could have some help. Heres the code I got off a friend to help me. //enemy=instance_nearest(x,y,enemy_basic) if ( action == action_normal || action == action_jumping || action = action_spring_jump || ((shield == 3 || shield == 4) && action == action_shield)) //if jumping or homing attack bouncing { if key_action_pressed && delay=0 && distance_to_object(objEnemy)<50 //If you press 'Z' and are close to an enemy { action = action_jumping //change to homing action sound_play(sndAirAttack) //Play homing sound //Lock on to nearest enemy (Notice I switch from Damizean's hsp,vsp function to speed and direction then back) if instance_number(objEnemy)>0 { if lock=1 && distance_to_object(objEnemy)<50 && objEnemy.y>=y //Go towards enemy {direction=point_direction(x,y,objEnemy.x,objEnemy.y) speed=5 hsp=0 vsp=0} else if lock=1 && speed>0 //Cancel lock (too far away from enemies) {lock=0 hsp=hspeed vsp=vspeed speed=0} } else if lock=1 && speed>0 //Cancel lock (If no enemies are present) {lock=0 hsp=hspeed vsp=vspeed speed=0} //If there is a wall between you and an enemy, stop homing attack (also applies to layers) if instance_number(objEnemy)>0 { if collision_line(x,y,objEnemy.x,objEnemy.y,objSolid,1,1) && lock=1 {vsp=0 hsp+=animation_direction*6 lock=0 speed=0} else if collision_line(x,y,objEnemy.x,objEnemy.y,objHigh,1,1) && lock=1 && layer=0 {vsp=0 hsp+=animation_direction*6 lock=0 speed=0} else if collision_line(x,y,objEnemy.x,objEnemy.y,objLow,1,1) && lock=1 && layer=1 {vsp=0 hsp+=animation_direction*6 lock=0 speed=0} else if collision_line(x,y,objEnemy.x,objEnemy.y,objBridge,1,1) && lock=1 {vsp=0 hsp+=animation_direction*6 lock=0 speed=0} } } } if instance_number(objEnemy)>0 && distance_to_object(objEnemy)<50//Locked on (enemy must be in-line or below Sonic, not above) {lock=1} if lock=1 && distance_to_object(objEnemy)<50 && instance_exists(objLock)=0 {instance_create(objEnemy.x,objEnemy.y,objLock)}[/CODE] Ive had other people check it out and so far NO ONE can figure it out, I sent it back to the guy who gave it to me but I never heard from him after that. And he even says he doesnt have a clue it was something slap together. So please can anyone help me out? Thanks!
  2. I saw a sonic satam gameplay video that the game never got released, Now I saw That it had 3 different spins for his spinball form. Seen in this video it shows a type chainsaw move that can cut through things, And another is a type spike blast where he shoots his quills out in all directions killing enemies. I was wondering how to do those in game maker, Or how one would. Using the genesis engine of course Im willing to try, But I have no where to begin. Can anyone be willing to tell me how this would be done?
  3. So take it out? Sorry, I took it out and it still did the samething, Any other ideas?
  4. Hello, How can I start this?, Umm...I was browsing through the old forums yesterday for codes and stuff things might help me with my own game. I got a crumbling cliff codes and stuff, You know?, From Green Hill in sonic 1?. Yeah, That. Basically it works fine, But whenever the room starts it crumbles on its own. NOT when sonic steps on it. Ill post the codes I got: objGimmickWeakPlatform (parent) Create: ObjectActivated = false; ObjectTimer = 0;[/CODE] Step: [CODE] // ---- Check if the collapse is activated ---------------------- if (ObjectActivated == true) { // ---- Count down timer for collapse ----------------------- ObjectTimer = max(ObjectTimer - (1000/60)*global.GameplayInterval, 0); if (ObjectTimer == 0) instance_destroy(); } else if (collision_rectangle(x-3, y-1, x+sprite_width+3, y+1, objPlayer, false, true)) { ObjectTimer = 300; ObjectActivated = true; }[/CODE] Destroy: [CODE] // --- Setup falling platforms --- var _ObjectHandle, _offset, _timing, _left, _top; for (_offset=0; _offset<(sprite_width/16)+(sprite_height/16-1); _offset+=1) { _left = _offset; _top = (sprite_height/16-1); _timing = 0; repeat (min(_offset+1, sprite_height/16)) { if (_left<(sprite_width/16)) { _ObjectHandle = instance_create(x+(_left*16), y+(_top*16), objGimmickWeakPlatformPiece); _ObjectHandle.sprite_index = sprite_index; _ObjectHandle.Left = _left; _ObjectHandle.Top = _top; if (PlatformOrientation==consObjectOrientationLeft) //consObjectOrientationLeft = 1 _ObjectHandle.ObjectTimer = 50*((sprite_width/16)-_left)+(_timing*25); else _ObjectHandle.ObjectTimer = 50*(_left)+(_timing*25); } _left = max(_left-1, 0); _top = max(_top-1, 0); _timing += 1; } }[/CODE] Okay for the next object Ive basically got the actual object basically. Create: [CODE] Speed = 0; Gravity = 0; GravityForce = 0.2; // 0.2 when active TopGravity = 8; ObjectTimer = 0; Left = 0; Top = 0;[/CODE] Step: [CODE] // ---- Count down timer for collapse ----------------------- ObjectTimer = max(ObjectTimer - (1000/60), 0); if (ObjectTimer == 0) { x += Speed; y += Gravity; Gravity = min(Gravity+GravityForce, TopGravity); }[/CODE] Outside of room: Destroy the instance Draw: [CODE]draw_sprite_part(sprite_index, floor(image_index), Left, Top, 16, 16, x, y);[/CODE] Thats all for the coding, Just..It works completely fine how it should But it gets destroyed before sonic even has a chance to step on it to make it crumble under his feet. Any help?
  5. Well, Im not having the problem anymore after Pro Shadowblaze helped me out on msn, But the issue is sticking all 3 peices on the grid without the 2 bottom haves disappearing, I put on half on there then the top, Everything is A-Okay. I put the second bottom peice on the other disappears, I put it the other way around THAT one disappears, It Pee's me off. Can anyone help me with that?
  6. Heh, You could say Im a natural at confusing people with my sentences --- And, I actually used yours coz that way it stayed and didnt over lap eacher. ^^'
  7. I got the layering working and I got the positioning to work so it dont over ride, But when sonic goes to run around it he suddenly appears at the top of the loop, And it happens BOTH ways. EDIT: And sorry about my bad english, I have trouble bringing my words out to talk, No Im not retarded Lol I just have trouble talking, And..I was in a rush at the time. Lol
  8. Cutting it into 2 halves hey?....Hmm...Would the would it be it still work the same as having the four peices of ramps to make one?. EDIT: Yeah, Cutting 2 halves isnt my cup of tea. I tried to do it and now Its a pain trying to get them close to each other while each half keeps over righting the other.
  9. Now I got loops and everything in my game, Just, I wanna add the original green hill zone sprite that is from sonic 1, Now its a full loop sprite. I was wondering, How do I get it as a solid but make sonic go around it, Heres the loop that I mean: http://www.themysticalforestzone.com/sprites/Sonic/backgorund_idems/greenhillzone5kh.png Can anyone help me out?
  10. I can draw like that, and that animation is pretty amazing, See id be able to draw my own sprites for my game, Just, Idk how to animate or anything like that which sucks, Anyhow. Nice job!
  11. Im still having trouble with what I want, Coz I changed it back to just the 2 rooms, but when it goes back to the roomtest room [yes I havent gone to change it yet] It goes back to the start of that along with the room changer thing, Ill email you, Or if you have msn Ill be able to send it through that and you take a look for me?, Coz spike helped with the room changing problem just the placement is a bit screwy.
  12. Hey PSB, With the code that you said put in the creation code of objHub, I just gotta ask, How can I change that so it works to put to make it go to the room I wish for it to go to, Instead of having it just only go "Next room" In the actual object itself, Coz atm Im making more than one object just to go in and out of tails workshop and Im making like 4 different rooms which is making progress of my game oh so confusing, Think you could help me out making it simpler to the mind and IQ such as myself? Lol.
  13. Thanks. Do you have msn so I can send it over?
  14. Basically Im using the Genesis engine, It has a starting position object for it that spawns the player but its only for when the menu has it, in this case the character menu to spawn sonic, Or tails or knuckles. And variables ground and relative_angle are in objSonic
×
×
  • Create New...