
EDuke32 Scripting "CON coding help"
#1111 Posted 13 January 2013 - 04:32 PM
#1112 Posted 14 January 2013 - 07:01 AM
RichardStorm, on 13 January 2013 - 04:32 PM, said:
annoying problem with mapster editor: how to get out of the window MAPSTER, or minimize it to switch to other applications such as text editor or image editor ?
it is very difficult to get out of the maspter window by pressing the windows key ...
and it crash ofen at closing
#1113 Posted 14 January 2013 - 07:06 AM
Mapster has crashed at exit for a couple of years now for me, I think I did report it, but I expect the devs were busy and I never cared that much as it only does it when it's already seemingly exited.
#1114 Posted 14 January 2013 - 10:49 AM
High Treason, on 14 January 2013 - 07:06 AM, said:
Does removing/renaming nedmalloc.dll fix it?
#1115 Posted 15 January 2013 - 08:41 AM
apparently there is no crash this time in my side
a list of commands for the mapster console ??
what was so special about using the console?
#1116 Posted 15 January 2013 - 03:59 PM
#1117 Posted 16 January 2013 - 03:30 AM
Mark., on 15 January 2013 - 03:59 PM, said:
how to make a no shade frame in an animation, in order to create a flash effect when the monster shot the player ?
#1118 Posted 16 January 2013 - 05:50 AM
#1119 Posted 16 January 2013 - 06:26 AM
Mblackwell, on 16 January 2013 - 05:50 AM, said:
not for the entire level but for a sprite only, on a specific frame,
#1120 Posted 16 January 2013 - 10:29 AM
Edit. I meant defs.con not def code
This post has been edited by Drek: 16 January 2013 - 06:16 PM
#1121 Posted 16 January 2013 - 03:20 PM
if you have this code somewhere...
#1122 Posted 16 January 2013 - 04:25 PM
zazo, on 16 January 2013 - 03:20 PM, said:
if you have this code somewhere...
The guts of the code for that is in "state slipperycode" in PLAYERPLUS.CON
#1123 Posted 20 January 2013 - 02:01 PM
gamevar that_actor 0 0
gamevar distance 0 0
gamevar tilenum 0 0
gamevar temp 0 0
gamevar temp2 0 0
gamevar xpos 0 0
gamevar ypos 0 0
gamevar zpos 0 0
gamevar xpos2 0 0
gamevar ypos2 0 0
gamevar zpos2 0 0
gamevar angle 0 0
gamevar angle2 0 0
gamevar sectorvar 0 0
gamevar sectorvar2 0 0
gamevar thatactor 0 0
gamevar wallvar 0 0
gamevar shotrange 0 1
state squarethreedistance // (xpos, ypos, zpos, xpos2, ypos2, zpos2) returns square of distance in temp
subvarvar xpos xpos2
subvarvar ypos ypos2
subvarvar zpos zpos2
divvar zpos 16 //16384z = 1024xy
mulvarvar xpos xpos
mulvarvar ypos ypos
mulvarvar zpos zpos
addvarvar xpos ypos
addvarvar xpos zpos
setvarvar temp xpos
ends
state threedistance
state squarethreedistance
sqrt temp temp
ends
onevent EVENT_GAME
ifactor APLAYER {
getplayer[THISACTOR].posx xpos
getplayer[THISACTOR].posy ypos
getplayer[THISACTOR].posz zpos
getplayer[THISACTOR].ang angle
getplayer[THISACTOR].cursectnum sectorvar
getplayer[THISACTOR].horiz angle2
subvar angle2 100
mulvar angle2 -2048
cos temp angle
sin temp2 angle
hitscan xpos ypos zpos sectorvar temp temp2 angle2 sectorvar2 wallvar thatactor xpos2 ypos2 zpos2 0xFFFF0030
state threedistance
setvarvar shotrange temp
}
endevent
onevent EVENT_GAME
ifactor SHOTSPARK1 {
getactor[THISACTOR].htg_t 8 that_actor ifvarn that_actor -1 {
/*getactor[that_actor].picnum tilenum
switch tilenum
case LIZTROOPONTOILET:
case LIZTROOPSTAYPUT:
case LIZTROOPSHOOT:
case LIZTROOPJETPACK:
case LIZTROOPDUCKING:
case LIZTROOPRUNNING:
case LIZTROOP:
//case OCTABRAIN:
//case OCTABRAINSTAYPUT:
case COMMANDER:
case COMMANDERSTAYPUT:
//case EGG:
case PIGCOP:
case PIGCOPSTAYPUT:
case PIGCOPDIVE:
case LIZMAN:
case LIZMANSTAYPUT:
case LIZMANSPITTING:
case LIZMANFEEDING:
case LIZMANJUMP:
//case GREENSLIME:
//case ROTATEGUN:
case NEWBEAST:
//case APLAYER:
setvar temp 1
break
default:
setvar temp 0
break
endswitch
ifvare temp 1 {*/
dist distance THISACTOR that_actor
/*ifvare distance 30 {
//state blood_sprinkle
} else ifvarl distance 320 { // legshot
//state blood_sprinkle
getactor[that_actor].htextra temp
subvar temp 3
setactor[that_actor].htextra temp
} else ifvarl distance 520 {
//state blood_sprinkle
} else */ifvarl distance 768 ifspawnedby APLAYER ifrnd 64 { // headshot
// bloody mess
//state blood_sprinkle
//state random_wall_jibs
//soundonce SQUISHED
// damage calc
getactor[THISACTOR].owner temp
setactor[that_actor].htowner temp
getactor[THISACTOR].yvel temp
setactor[that_actor].htpicnum temp
getactor[that_actor].htextra temp2
/*ifvare temp SHOTGUN {
addvarvar temp2 10
} else {
addvarvar temp2 60
}*/
//mulvar temp2 4
subvarvar temp2 shotrange
ifvarvarl temp2 0
setvar temp2 -1
setactor[that_actor].htextra temp2
addlogvar temp2
}
/*}*/
}
}
endevent
#1124 Posted 22 January 2013 - 03:23 PM
Dr. Kylstein, on 20 January 2013 - 02:01 PM, said:
I am literally just answering this question and not reading your code (to save myself time).
In general, htextra is processed by the actor in its code with the ifhitweapon command. EVENT_GAME occurs after the actor code has been processed, so htextra will have been reset by then and manipulating it will not have the desired effect.
#1126 Posted 22 January 2013 - 06:23 PM
Trooper Dan, on 22 January 2013 - 03:23 PM, said:
Totally understandable. I probably should have removed the commented out part.
Trooper Dan, on 22 January 2013 - 03:23 PM, said:
That does fit my observations. I think perhaps I misinterpreted the locational damage code and that adding to the htextra was done in the off chance that some other damage was stored there rather than the original bullet. Is there any other way to alter the damage for one hitscan shot?
#1127 Posted 24 January 2013 - 06:18 AM
Another thing: the command endofgame ends the episode, but is a command to finish the level and access the next level ?
#1128 Posted 24 January 2013 - 08:21 AM
Setactor[return].pal
About ending the current level. I'm pretty sure it can be done, but I've never done it so I can't help. Did you look through the eduke wiki commands list?
#1129 Posted 24 January 2013 - 08:29 AM
#1130 Posted 24 January 2013 - 08:36 AM
Drek, on 24 January 2013 - 08:21 AM, said:
Setactor[return].pal
About ending the current level. I'm pretty sure it can be done, but I've never done it so I can't help. Did you look through the eduke wiki commands list?
the command startlevel works well, but my probleme is to jump to the next level in the current episode... is a command to detect the number of the current level and add 1 to it in the startlevel ... im very bad, i dont find this in the wiki
#1131 Posted 24 January 2013 - 08:48 AM
zazo, on 24 January 2013 - 08:36 AM, said:
I found myself:
gamevar currentlevel 0 1
gamevar currentvolume 0 1
setvarvar currentlevel LEVEL
setvarvar currentvolume VOLUME
addvar currentlevel 1
startlevel currentlevel currentvolume
#1132 Posted 24 January 2013 - 10:00 AM
zazo, on 24 January 2013 - 06:18 AM, said:
// blue
spawn ACCESSCARD
// red
espawn ACCESSCARD
setactor[RETURN].pal 21
// yellow
espawn ACCESSCARD
setactor[RETURN].pal 23
#1133 Posted 29 January 2013 - 12:34 PM
Hendricks266, on 24 January 2013 - 10:00 AM, said:
// blue
spawn ACCESSCARD
// red
espawn ACCESSCARD
setactor[RETURN].pal 21
// yellow
espawn ACCESSCARD
setactor[RETURN].pal 23
thanks !
Arg ! eduke crash with the message "too many sprite spawned" !!
a way to avoid this by the code??
#1134 Posted 29 January 2013 - 01:35 PM
#1135 Posted 04 February 2013 - 02:57 PM
#1136 Posted 05 February 2013 - 05:16 AM
#1137 Posted 05 February 2013 - 05:27 AM
Alan, on 05 February 2013 - 05:16 AM, said:
i owned
#1138 Posted 05 February 2013 - 05:30 AM
zazo, on 05 February 2013 - 05:27 AM, said:
thanks a lot ! although it works in dosbox, editart remains the best art editor
#1139 Posted 17 February 2013 - 10:19 AM
in particular: vegetation, trees ... ?