Hello Guest, please login or register.
Did you miss your activation email?
Login with username, password and session length.

Pages: [1]   Go Down

Author Topic: [Request / Listing] House enter/exit script or example?  (Read 1170 times)

0 Members and 1 Guest are viewing this topic.
[Request / Listing] House enter/exit script or e...
« on: June 26, 2006, 12:25:01 am »
  • ^This is my sprite comments char
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Posts: 226
well i'm trying to make a code taht when links enter to a house a variable called global.house gets a value (a identifier to know where to links have to start when he exits)

but i cant figure out how to do the creation of link code, any help?
« Last Edit: February 11, 2012, 09:32:55 am by Niek »
Logged



i'm working on:

I support and i'm part of the team of:

Goodnight

Once and future Captain
Re: House enter/exit script or example?
« Reply #1 on: June 26, 2006, 01:25:32 am »
  • With a Capital G
  • *
  • Reputation: +1/-0
  • Offline Offline
  • Gender: Male
  • Posts: 706
Do you create Link via code in each room? Or have you placed an instance of Link in each room? Or do you have a persistent Link?

Either way, you can do this in the Room Creation Code. In the House room's RCC, set global.house to whatever value means he's in the house.

Then in the Outside room's RCC, check if the variable equals that value, and if so, do either:
Code: [Select]
instance_create(x_pos, y_pos, objLink)If a Link doesn't already exist in that room, or:
Code: [Select]
objLink.x = x_pos
objLink.y = y_pos
If Link already exists or is persistent.

The x_pos and y_pos should be changed to the position you want Link to appear at.
Logged
Re: House enter/exit script or example?
« Reply #2 on: June 26, 2006, 12:16:45 pm »
  • Txet Lanosrep
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Gender: Male
  • Posts: 700
Lol Litium, don't want to use mine?  You can if you want lol.
Logged

Retro
  • TITANIC
Re: House enter/exit script or example?
« Reply #3 on: June 26, 2006, 05:45:12 pm »
  • ^This is my sprite comments char
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Posts: 226
i alredy figured it out, i make an object that creatres link using diferents values so if global.house_linkhouse=true link starts on thee xit of that house and if global.house_npchouse1=true starts on that exit
Logged



i'm working on:

I support and i'm part of the team of:
Re: House enter/exit script or example?
« Reply #4 on: June 26, 2006, 08:19:14 pm »
  • Along Time Ago
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Gender: Male
  • Posts: 231
Retro urs don't even work.
Logged

mit

Re: House enter/exit script or example?
« Reply #5 on: June 26, 2006, 10:33:28 pm »
  • QBASIC programmer since age 4. Take that, world.
  • *
  • Reputation: +0/-0
  • Offline Offline
  • Posts: 1079
http://www.kousougames.co.uk/stuff/Overworld.zip

Yay.

Probably doesn't help anyone.
Logged
Programmer / Spriter / Level designer / Game Director / Web Designer / Music Sequencer for
Random Highscore table:

Play the Kousou Arcade today!
  • Kousou Games
Pages: [1]   Go Up

 


Contact Us | Legal | Advertise Here
2013 © ZFGC, All Rights Reserved



Page created in 0.063 seconds with 51 queries.