dMZX Forums: Sprite SNOW engine - dMZX Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Sprite SNOW engine or atleast over the overlay

#1 User is offline   merder 

  • Unintelligible Member
  • PipPipPip
  • Group: Members
  • Posts: 339
  • Joined: 08-February 05
  • Location:netherlands

Posted 24 September 2006 - 09:59 AM

i never before used sprites before so i thougth is better to try it with someing safe like rain or snow so i decided to use snow.
so now i have a few questions.
1. are spritea on the same layer as the overlay?
2. could anyone give me an example engine?
This is not real.
You did not see this.
You weren't here.

My own story forum(dutch(holland))
0

#2 User is offline   Val 

  • ring ring zap
  • PipPipPipPipPip
  • Group: Members
  • Posts: 2,233
  • Joined: 19-February 04
  • Gender:Female
  • Location:Bartholomew

Posted 24 September 2006 - 01:20 PM

1. Sprites can be either below or above the overlay; by default, they're below, but you can set them to be above by setting "spr#_overlay" to 1. Keep in mind, though, that they're ALWAYS above the playing field.

2. ask lancer

This post has been edited by Guy: 24 September 2006 - 01:21 PM

0

#3 User is offline   hob nado 

  • Ancient Member
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 4,718
  • Joined: 23-September 00
  • Gender:Male

Posted 24 September 2006 - 01:42 PM

merder: An engine you might look into is the rain engine in Honor Quest 2. There's a dark and rainy board towards the end of the game - since it's an old game, of course, it uses the overlay, but you could probably apply the same principles really easily to using sprites.

Or if you want, use the start of Weirdland 6. I ripped that engine off several times =)
0

#4 User is offline   merder 

  • Unintelligible Member
  • PipPipPip
  • Group: Members
  • Posts: 339
  • Joined: 08-February 05
  • Location:netherlands

Posted 24 September 2006 - 03:41 PM

Esdemo1, on Sep 24 2006, 01:42 PM, said:

Or if you want, use the start of Weirdland 6. I ripped that engine off several times =)

its a missing game. so i cant look at it for a reference not to mention ripping the engine.

This post has been edited by merder: 24 September 2006 - 03:42 PM

This is not real.
You did not see this.
You weren't here.

My own story forum(dutch(holland))
0

#5 User is offline   Tixus 

  • cancelled by fox
  • Group: DigiStaff
  • Posts: 1,841
  • Joined: 11-December 00
  • Gender:Male
  • Location:Springfield

Posted 24 September 2006 - 06:44 PM

Yeah..You kinda didn't release that one, Es.
0

#6 User is offline   hob nado 

  • Ancient Member
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 4,718
  • Joined: 23-September 00
  • Gender:Male

Posted 24 September 2006 - 09:16 PM

Oh, I released it back in the day. If it's not up, well, I'll see what I can do. Probably better to get the engine from HL2, or just roll your own - local counters make it much easier to do now.
0

#7 User is offline   Goshi 

  • I'm dreadful of DRAGON.
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 4,146
  • Joined: 23-April 01
  • Gender:Male
  • Location:Hihoukan

Posted 25 September 2006 - 01:50 AM

Here

http://www.digitalmz...?showtopic=3255

EDOT: It looks like the link is dead though. Get to work Es.

This post has been edited by Goshi: 25 September 2006 - 01:50 AM

0

#8 User is offline   Pyro1588 

  • wojtek
  • PipPip
  • Group: Members
  • Posts: 145
  • Joined: 20-October 02
  • Gender:Male
  • Location:Minnesota

Posted 25 September 2006 - 06:16 PM

here's a quick rain engine i whipped up in a few minutes. it's basic but it should give you an idea of what to do.
char edit '' to 1 1 3 2 6 4 12 8 8 0 0 0 0 0
char edit '' to 0 0 2 2 6 4 46 28 8 54 0 0 0 0
char edit '' to 0 0 0 0 4 4 111 28 8 54 65 0 0 0
char edit '' to 0 0 0 0 0 0 99 0 0 34 65 0 0 0
set "commands" to "(-1>>1)"
set "drops" to 100
. "number of drops"
set "vch0,0" to 128
set "vco0,0" to 11
set "vch1,0" to 129
set "vco1,0" to 11
set "vch2,0" to 130
set "vco2,0" to 11
set "vch3,0" to 131
set "vco3,0" to 11
loop start
set "spr&loopcount&_refx" to 0
set "spr&loopcount&_refy" to 0
set "spr&loopcount&_width" to 1
set "spr&loopcount&_height" to 1
set "spr&loopcount&_overlay" to 1
set "spr&loopcount&_vlayer" to 1
set "spr&loopcount&_x" to random 0 to 79
inc "spr&loopcount&_x" by "scrolledx"
set "spr&loopcount&_y" to random 0 to 24
inc "spr&loopcount&_y" by "scrolledy"
set "spr&loopcount&_cwidth" to random 5 to 10
. "the distance it will fall"
put c?? Sprite "loopcount" at "spr&loopcount&_x" "spr&loopcount&_y"
loop for "drops"
: "do"
wait for 1
loop start
dec "spr&loopcount&_x" by "('spr('loopcount')_cwidth'>=3)"
inc "spr&loopcount&_y" by "('spr('loopcount')_cwidth'>=3)"
dec "spr&loopcount&_cwidth" by 1
inc "spr&loopcount&_refx" by "('spr('loopcount')_cwidth'<4)"
if "spr&loopcount&_cwidth" = 0 then "#killdrop"
loop for "drops"
goto "do"
: "#killdrop"
set "spr&loopcount&_off" to 1
set "spr&loopcount&_refx" to 0
set "spr&loopcount&_x" to random 0 to 79
inc "spr&loopcount&_x" by "scrolledx"
set "spr&loopcount&_y" to random 0 to 24
inc "spr&loopcount&_y" by "scrolledy"
set "spr&loopcount&_cwidth" to random 5 to 10
put c?? Sprite "loopcount" at "spr&loopcount&_x" "spr&loopcount&_y"
goto "#return"

edit: fixed for scrolling

This post has been edited by Pyro1588: 25 September 2006 - 06:24 PM

<Tox> bah. I may as well give in and shop australia. D:
<pyro1588> "welcome to australia, can i help you find what you're looking for?"
<Tox> pyro1588, I'm giving you the most reproachful of glares right now.
--------
Go show those nutty Koreans what us crazy Europeans are made of pirate.gif pirate.gif pirate.gif - Saike
<exophase> The old Commodore strategy of, "Go friggin' bankrupt!"
<wervyn> Go away! I'm writing the same engine I always do!
0

#9 User is offline   CHEZZY 

  • sometimes... I dream about cheese
  • PipPipPipPip
  • Group: Members
  • Posts: 996
  • Joined: 08-April 06
  • Location:New Zealand

Posted 25 September 2006 - 10:54 PM

Wow thats heavy rain nice engine though!
user posted image
koji: SCRUMTRELLESCENT!
0

#10 User is offline   Bramble 

  • Veteran Member
  • PipPipPipPipPip
  • Group: Members
  • Posts: 2,869
  • Joined: 19-March 04
  • Gender:Not Telling

Posted 26 September 2006 - 12:16 AM

Oh this is such a waste of time. Just make the background white dots with a separate robot to make the snow char scroll downward.

(hee hee)
0

#11 User is offline   T-Bone 

  • Wastelander
  • PipPipPipPipPip
  • Group: Members
  • Posts: 2,487
  • Joined: 16-August 02
  • Gender:Male
  • Location:Canada

Posted 26 September 2006 - 12:18 AM

Bramble, on Sep 25 2006, 07:16 PM, said:

Oh this is such a waste of time. Just make the background white dots with a separate robot to make the snow char scroll downward.

(hee hee)

hahaha that's what I do.

EDIT: Wow... Pyro your engine crashed my MZX haha weird. Think its the multible chars or something. Least it worked for others.

EDIT (2): Actually it has nothing to do with the char edit command. Strange enough, after I removed those lines of code it still crashed. Wonder if has something to do with the clipboard saving or maybe its a problem with MZX. But if that were true Chezzy wouldn't of been able to test it.

GASP! I wonder what it could be!

This post has been edited by T-bone6: 26 September 2006 - 12:27 AM

0

#12 User is offline   merder 

  • Unintelligible Member
  • PipPipPip
  • Group: Members
  • Posts: 339
  • Joined: 08-February 05
  • Location:netherlands

Posted 26 September 2006 - 06:01 PM

the dot char scrolling is also used( in battle) but the sprite snow i'm using in towns and such where the snow some times goes over the overlay(he houses roofs and the talking engine(can be done with simple ma in mzx(scrolled x/y + something))the only annoying part is placing the talkobjects so the don't overwrite the rooftops and such.

[edit]i tried the engine but my robotics editor did't allow the multi char editting commands(for the rest it woked fine).

This post has been edited by merder: 26 September 2006 - 06:10 PM

This is not real.
You did not see this.
You weren't here.

My own story forum(dutch(holland))
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users